|Aug 6, 2006, 09:32 AM||#1|
Getting a notification when a nib loads
I'm loading a nib with:
[NSBundle loadNibNamed:@"MyNib" owner:self];
BTW awakeFromNib doesn't work
|Aug 6, 2006, 01:08 PM||#3|
Doesn't matter. I've figured out that it's not the secondary nib that's the problem but the document nib.
It seems that the
- - (void)windowControllerDidLoadNib:(NSWindowController *) aController
I was trying to display a sheet to appear when a new document was created or opened (something like that anyway. I can't be bothered to explain fully ).
I thought that if I put the [NSApp beginSheet: etc:] message in the windowControllerDidLoadNib method then the sheet would appear after the nib had loaded and it would 'stick' to the window. Why doesn't that work.
Anyway, I fixed it by putting it in a menu so the nib would of loaded by then anyway.
|Aug 6, 2006, 01:12 PM||#4|
It appears from the documentation that the method blocks until the nib is loaded successfully (as opposed from delaying it somewhere in the run loop or a secondary thread) because it returns a BOOL that indicates whether the load was a success or not.
|Thread Tools||Search this Thread|
|thread||Thread Starter||Forum||Replies||Last Post|
|iPhone: I cannot receive any twitter push notification or update the setting of notification.||tkwlee||iOS 7||8||Aug 31, 2014 08:16 PM|
|Chrome: notification not via Notification Centre anymore||arnoz||Mac Applications and Mac App Store||0||May 29, 2014 11:38 AM|
|Getting notification AND email for Shared Calendar, I only wait notification||sflomenb||iCloud and Apple Services||0||Nov 27, 2012 11:00 PM|
|Notification center: dismiss notification instead of app||NoSmokingBandit||OS X 10.8 Mountain Lion||0||Nov 6, 2012 10:21 PM|
All times are GMT -5. The time now is 09:30 PM.