Upped the MenuTunes version constant in MainController.h
[MenuTunes.git] / MainController.h
1 /*
2  *      MenuTunes
3  *  MainController
4  *    App Controller Class
5  *
6  *  Original Author : Matthew Judy <mjudy@ithinksw.com>
7  *   Responsibility : Matthew Judy <mjudy@ithinksw.com>
8  *
9  *  Copyright (c) 2002-2003 iThink Software.
10  *  All Rights Reserved
11  *
12  */
13
14
15 #import <Cocoa/Cocoa.h>
16 #import <Carbon/Carbon.h>
17 #import <ITKit/ITKit.h>
18 #import <ITFoundation/ITFoundation.h>
19 #import <ITMTRemote/ITMTRemote.h>
20 #import "MTBlingController.h"
21
22 #define MT_CURRENT_VERSION 1500
23
24 @class StatusWindowController, MenuController, NetworkController;
25
26 @interface MainController : NSObject
27 {
28     ITStatusItem   *statusItem;
29     NSMutableArray *remoteArray;
30     ITMTRemote     *currentRemote;
31     
32     ITMTRemotePlayerRunningState  playerRunningState;
33     ITMTRemotePlayerPlaylistClass latestPlaylistClass;
34     
35     //Used in updating the menu automatically
36     NSTimer *refreshTimer;
37     NSString *_latestSongIdentifier, *_toolTip;
38         NSDictionary *_lastTrackInfo;
39
40     StatusWindowController *statusWindowController; //Shows status windows
41     MenuController *menuController;
42     NetworkController *networkController;
43     NSUserDefaults *df;
44     
45     MTBlingController *bling;
46     NSTimer *registerTimer;
47     BOOL timerUpdating, _checkingForServer, _popped, _open;
48     BOOL blinged;
49     NSLock *_serverCheckLock;
50 }
51 + (MainController *)sharedController;
52
53 - (void)menuClicked;
54
55 //Methods called from MenuController by menu items
56 - (NSDate*)getBlingTime;
57 - (void)blingTime;
58 - (void)blingNow;
59 - (BOOL)blingBling;
60
61 - (void)timerUpdate;
62
63 - (void)playPause;
64 - (void)nextSong;
65 - (void)prevSong;
66 - (void)fastForward;
67 - (void)rewind;
68 - (void)selectPlaylistAtIndex:(int)index;
69 - (void)selectSongAtIndex:(int)index;
70 - (void)selectSongRating:(int)rating;
71 - (void)selectEQPresetAtIndex:(int)index;
72 - (void)makePlaylistWithTerm:(NSString *)term ofType:(int)type;
73 - (void)showPlayer;
74 - (void)showPreferences;
75 - (void)showTestWindow;
76 - (void)quitMenuTunes;
77
78 //
79
80 - (void)setServerStatus:(BOOL)newStatus;
81 - (int)connectToServer;
82 - (BOOL)disconnectFromServer;
83 - (void)checkForRemoteServerAndConnectImmediately:(BOOL)connectImmediately;
84 - (void)networkError:(NSException *)exception;
85
86 //
87
88 - (ITMTRemote *)currentRemote;
89 - (void)clearHotKeys;
90 - (void)setupHotKeys;
91 - (void)closePreferences;
92 - (MenuController *)menuController;
93
94 - (void)showCurrentTrackInfo;
95
96 @end
97
98 @interface NSImage (SmoothAdditions)
99 - (NSImage *)imageScaledSmoothlyToSize:(NSSize)scaledSize;
100 @end