Incremental MT Checkin, adding the plugin files, and major project structure changes.
[MenuTunes.git] / ITMTRemote.h
1 /*
2  *  MenuTunes
3  *  ITMTRemote
4  *    Plugin definition for audio player control via MenuTunes
5  *
6  *  Original Author : Matt Judy <mjudy@ithinksw.com>
7  *   Responsibility : Matt Judy <mjudy@ithinksw.com>
8  *
9  *  Copyright (c) 2002 - 2003 iThink Software.
10  *  All Rights Reserved
11  *
12  *      This header defines the Objective-C protocol which all MenuTunes Remote
13  *  plugins must implement.  To build a remote, create a subclass of this
14  *  object, and implement each method in the @protocol below.
15  *
16  */
17
18 /*
19  * TO DO:
20  *
21  * - Capability methods
22  *
23  */
24
25 #import <Cocoa/Cocoa.h>
26
27 @protocol ITMTRemote
28
29 + (id)remote;
30 // Return an autoreleased instance of the remote.
31 // Should be very quick and compact.
32 // EXAMPLE:
33 //   + (id)remote
34 //   {
35 //       return [[[MyRemote alloc] init] autorelease];
36 //   }
37
38 - (NSString *)title;
39 // Return the title of the remote.
40
41 - (NSString *)description;
42 // Return a short description of the remote.
43
44 - (NSImage *)icon;
45 // Return a 16x16 icon representation for the remote.
46
47 - (BOOL)begin;
48 // Sent to the plugin when it should begin operation.
49
50 - (BOOL)halt;
51 // Sent to the plugin when it should cease operation.
52
53 - (NSArray *)sources;
54 - (int)currentSourceIndex;
55
56 - (NSArray *)playlistsForCurrentSource;
57 - (int)currentPlaylistIndex;
58
59 - (NSString *)songTitleAtIndex;
60 - (int)currentSongIndex;
61
62 - (NSString *)currentSongTitle;
63 - (NSString *)currentSongArtist;
64 - (NSString *)currentSongAlbum;
65 - (NSString *)currentSongGenre;
66 - (NSString *)currentSongLength;
67 - (NSString *)currentSongRemaining;
68
69 - (NSArray *)eqPresets;
70
71 - (BOOL)play;
72 - (BOOL)pause;
73 - (BOOL)goToNextSong;
74 - (BOOL)goToPreviousSong;
75 - (BOOL)goToNextPlaylist;
76 - (BOOL)goToPreviousPlaylist;
77
78 - (BOOL)switchToSourceAtIndex:(int)index;
79 - (BOOL)switchToPlaylistAtIndex:(int)index;
80 - (BOOL)switchToSongAtIndex:(int)index;
81 - (BOOL)switchToEQAtIndex:(int)index;
82
83 @end
84
85
86 @interface ITMTRemote : NSObject <ITMTRemote>
87
88 @end