annotate gui/app.h @ 23736:b807809ef9f8

Remove unnecessary #ifdef around the whole file.
author diego
date Mon, 09 Jul 2007 20:40:47 +0000
parents 3f0d00abc073
children 2dee54f0d8a0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
23077
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
1
23689
3f0d00abc073 Do not use leading underscores in multiple inclusion guards, they are reserved.
diego
parents: 23685
diff changeset
2 #ifndef GUI_APP_H
3f0d00abc073 Do not use leading underscores in multiple inclusion guards, they are reserved.
diego
parents: 23685
diff changeset
3 #define GUI_APP_H
23077
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
4
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
5 #include "bitmap.h"
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
6 #include "wm/ws.h"
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
7 #include "wm/wskeys.h"
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
8
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
9 // --- User events ------
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
10
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
11 #define evNone 0
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
12 #define evPlay 1
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
13 #define evStop 2
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
14 #define evPause 3
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
15 #define evPrev 6
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
16 #define evNext 7
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
17 #define evLoad 8
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
18 #define evEqualizer 9
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
19 #define evPlayList 10
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
20 #define evIconify 11
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
21 #define evAbout 12
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
22 #define evLoadPlay 13
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
23 #define evPreferences 14
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
24 #define evSkinBrowser 15
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
25 #define evPlaySwitchToPause 16
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
26 #define evPauseSwitchToPlay 17
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
27
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
28 #define evBackward10sec 18
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
29 #define evForward10sec 19
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
30 #define evBackward1min 20
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
31 #define evForward1min 21
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
32 #define evBackward10min 22
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
33 #define evForward10min 23
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
34
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
35 #define evHalfSize 301
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
36 #define evNormalSize 24
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
37 #define evDoubleSize 25
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
38 #define evFullScreen 26
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
39
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
40 #define evSetMoviePosition 27
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
41 #define evSetVolume 28
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
42 #define evSetBalance 29
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
43 #define evMute 30
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
44
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
45 #define evIncVolume 31
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
46 #define evDecVolume 32
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
47 #define evIncAudioBufDelay 33
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
48 #define evDecAudioBufDelay 34
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
49 #define evIncBalance 35
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
50 #define evDecBalance 36
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
51
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
52 #define evHelp 37
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
53
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
54 #define evLoadSubtitle 38
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
55 #define evDropSubtitle 43
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
56 #define evPlayDVD 39
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
57 #define evPlayVCD 40
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
58 #define evPlayNetwork 41
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
59 #define evLoadAudioFile 42
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
60 #define evSetAspect 44
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
61 #define evSetAudio 45
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
62 #define evSetVideo 46
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
63 #define evSetSubtitle 47
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
64 // 48 ...
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
65
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
66 #define evExit 1000
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
67
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
68 // --- General events ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
69
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
70 #define evFileLoaded 5000
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
71 #define evHideMouseCursor 5001
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
72 #define evMessageBox 5002
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
73 #define evGeneralTimer 5003
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
74 #define evGtkIsOk 5004
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
75 #define evShowPopUpMenu 5005
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
76 #define evHidePopUpMenu 5006
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
77 #define evSetDVDAudio 5007
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
78 #define evSetDVDSubtitle 5008
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
79 #define evSetDVDTitle 5009
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
80 #define evSetDVDChapter 5010
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
81 #define evSubtitleLoaded 5011
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
82 #define evSetVCDTrack 5012
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
83 #define evSetURL 5013
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
84
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
85 #define evFName 7000
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
86 #define evMovieTime 7001
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
87 #define evRedraw 7002
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
88 #define evHideWindow 7003
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
89 #define evShowWindow 7004
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
90 #define evFirstLoad 7005
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
91
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
92 // ----------------------
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
93
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
94 typedef struct
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
95 {
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
96 int msg;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
97 const char * name;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
98 } evName;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
99
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
100 extern int evBoxs;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
101 extern evName evNames[];
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
102
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
103 #define itNULL 0
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
104 #define itButton 101 // button
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
105 #define itHPotmeter 102 // horizontal potmeter
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
106 #define itVPotmeter 103 // vertical potmeter
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
107 #define itSLabel 104 // static label
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
108 #define itDLabel 105 // dynamic label
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
109 #define itBase 106
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
110 #define itPotmeter 107
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
111 #define itFont 108
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
112 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
113 #define btnPressed 0
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
114 #define btnReleased 1
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
115 #define btnDisabled 2
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
116 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
117 typedef struct
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
118 {
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
119 int type;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
120 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
121 int x,y;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
122 int width,height;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
123 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
124 int px,py,psx,psy;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
125 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
126 int msg,msg2;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
127 int pressed,tmp;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
128 int key,key2;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
129 int phases;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
130 float value;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
131 txSample Bitmap;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
132 txSample Mask;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
133 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
134 int fontid;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
135 int align;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
136 char * label;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
137 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
138 int event;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
139 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
140 int R,G,B;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
141 } wItem;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
142
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
143 typedef struct
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
144 {
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
145 wItem main;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
146 wsTWindow mainWindow;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
147 int mainDecoration;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
148
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
149 wItem sub;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
150 wsTWindow subWindow;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
151
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
152 wItem bar;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
153 wsTWindow barWindow;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
154 int barIsPresent;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
155
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
156 wItem menuBase;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
157 wItem menuSelected;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
158 wsTWindow menuWindow;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
159 int menuIsPresent;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
160
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
161 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
162 int NumberOfItems;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
163 wItem Items[256];
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
164 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
165 int NumberOfMenuItems;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
166 wItem MenuItems[64];
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
167 // ---
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
168 int NumberOfBarItems;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
169 wItem barItems[256];
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
170 } listItems;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
171
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
172 extern listItems appMPlayer;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
173
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
174 extern char * skinDirInHome;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
175 extern char * skinDirInHome_obsolete;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
176 extern char * skinMPlayerDir;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
177 extern char * skinMPlayerDir_obsolete;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
178 extern char * skinName;
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
179
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
180 extern void appInitStruct( listItems * item );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
181 extern void appClearItem( wItem * item );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
182 extern void appCopy( listItems * item1,listItems * item2 );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
183 extern int appFindMessage( unsigned char * str );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
184 extern int appFindKey( unsigned char * name );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
185
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
186 extern void btnModify( int event,float state );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
187 extern float btnGetValue( int event );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
188 extern void btnSet( int event,int set );
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
189
17bf4f4b0715 Gui --> gui
diego
parents:
diff changeset
190 #endif