Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Ivan Chen
Yes, Just heard that from one of my Mac team friends 'o- Is there any other way to observer such interprocess window events? Thanks Ivan Chen On Mar 9, 2011, at 9:20 AM, Quincey Morris wrote: > On Mar 8, 2011, at 16:17, Ivan Chen wrote: > >> What I really want to observer is the app iCal, wh

Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Quincey Morris
On Mar 8, 2011, at 16:17, Ivan Chen wrote: > What I really want to observer is the app iCal, when I register the > notification the iCal may not be launched yet. > So I have to pass nil to observer every window, but it just doesn't work > 'o-!!! > Why? Because you can't get notifications from w

Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Ivan Chen
Hi, Guys What I really want to observer is the app iCal, when I register the notification the iCal may not be launched yet. So I have to pass nil to observer every window, but it just doesn't work 'o-!!! Why? The truth is I also register lots of notification like : [self registerDefaultNotificat

Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Jim McGowan
>> with "onObject:nil" you are not providing an NSWindow instance to observe > > > Not so - passing nil means "observe all windows". Ah yes, of course it does ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or

Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Graham Cox
On 08/03/2011, at 10:45 PM, Jim McGowan wrote: > with "onObject:nil" you are not providing an NSWindow instance to observe Not so - passing nil means "observe all windows". --Graham ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do

Re: About notification NSWindowDidMiniaturizeNotification

2011-03-08 Thread Jim McGowan
> > I write the following code and try to observe the window miniaturized > notification, it doesn't work, can anyone tell me why? > ... > // Observing window status > [self registerDefaultNotification:NSWindowDidMiniaturizeNotification > withSelector:@selector(windowMiniaturized:) onObjec

About notification NSWindowDidMiniaturizeNotification

2011-03-07 Thread Ivan Chen
Hi, Guys I write the following code and try to observe the window miniaturized notification, it doesn't work, can anyone tell me why? - (void)windowMiniaturized:(NSNotification*)notification { NSLog(@"%@", notification); } - (void)registerDefaultNotification:(NSString*)notification wi