X-Git-Url: http://git.ithinksw.org/ITKit.git/blobdiff_plain/f9f1dcb9f4e7bcd6ea0e7a7cbb386bd073a90d47..f9ac1766dbe420e477be299e49b2d8f69cafe5ec:/Showcase/Controller.m diff --git a/Showcase/Controller.m b/Showcase/Controller.m index a8914aa..16b5c0b 100755 --- a/Showcase/Controller.m +++ b/Showcase/Controller.m @@ -204,15 +204,15 @@ [statusWindow setExitEffect:[[ITPivotWindowEffect alloc] initWithWindow:statusWindow]]; } -- (IBAction)showStatusWindow:(id)sender +- (IBAction)toggleStatusWindow:(id)sender { - [[statusWindow contentView] setNeedsDisplay:YES]; - [statusWindow appear:self]; -} - -- (IBAction)hideStatusWindow:(id)sender -{ - [statusWindow vanish:self]; + if ( ([statusWindow visibilityState] == ITTransientStatusWindowHiddenState) || + ([statusWindow visibilityState] == ITTransientStatusWindowVanishingState) ) { + [[statusWindow contentView] setNeedsDisplay:YES]; + [statusWindow appear:self]; + } else { + [statusWindow vanish:self]; + } } - (IBAction)changeWindowSetting:(id)sender @@ -279,6 +279,7 @@ { } + /*************************************************************************/ #pragma mark - #pragma mark NSWindow DELEGATE METHODS