Fixed it so that if you double click on the MT icon or call it to open,
authorKent Sutherland <ksuther@ithinksw.com>
Mon, 11 Apr 2005 00:05:23 +0000 (00:05 +0000)
committerKent Sutherland <ksuther@ithinksw.com>
Mon, 11 Apr 2005 00:05:23 +0000 (00:05 +0000)
it will show the prefs window once it is launched.

MainController.m

index eaaa953..c2502c5 100755 (executable)
@@ -189,13 +189,6 @@ static MainController *sharedController;
        _open = YES;
 }
 
        _open = YES;
 }
 
-- (void)applicationDidBecomeActive:(NSNotification *)note
-{
-       if (_open && !blinged && ![NSApp mainWindow] && ![[StatusWindow sharedWindow] isVisible]) {
-               [[MainController sharedController] showPreferences];
-       }
-}
-
 - (ITMTRemote *)loadRemote
 {
     NSString *folderPath = [[NSBundle mainBundle] builtInPlugInsPath];
 - (ITMTRemote *)loadRemote
 {
     NSString *folderPath = [[NSBundle mainBundle] builtInPlugInsPath];
@@ -1520,7 +1513,7 @@ static MainController *sharedController;
             [refreshTimer invalidate];
             [refreshTimer release];
             refreshTimer = nil;
             [refreshTimer invalidate];
             [refreshTimer release];
             refreshTimer = nil;
-                       [[NSNotificationCenter defaultCenter] removeObserver:self];
+                       [[NSNotificationCenter defaultCenter] removeObserver:self name:@"ITMTTrackChanged" object:nil];
                        [statusItem setEnabled:YES];
                        [statusItem setToolTip:@"iTunes not running."];
             [self clearHotKeys];
                        [statusItem setEnabled:YES];
                        [statusItem setToolTip:@"iTunes not running."];
             [self clearHotKeys];
@@ -1556,6 +1549,12 @@ static MainController *sharedController;
     [[NSStatusBar systemStatusBar] removeStatusItem:statusItem];
 }
 
     [[NSStatusBar systemStatusBar] removeStatusItem:statusItem];
 }
 
+- (void)applicationDidBecomeActive:(NSNotification *)note
+{
+       if (_open && !blinged && ![NSApp mainWindow] && ([[StatusWindow sharedWindow] exitMode] == ITTransientStatusWindowExitAfterDelay)) {
+               [[MainController sharedController] showPreferences];
+       }
+}
 
 /*************************************************************************/
 #pragma mark -
 
 /*************************************************************************/
 #pragma mark -