Rev 5793 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 5793 | Rev 5795 | ||
---|---|---|---|
Line 18... | Line 18... | ||
18 | #include "..\lib\obj\libimg_lib.h" |
18 | #include "..\lib\obj\libimg_lib.h" |
19 | #include "..\lib\obj\libini.h" |
19 | #include "..\lib\obj\libini.h" |
Line 20... | Line 20... | ||
20 | 20 | ||
Line -... | Line 21... | ||
- | 21 | #include "..\lib\patterns\libimg_load_skin.h" |
|
- | 22 | ||
- | 23 | #define ABOUT_MESSAGE "'Pixies Player v1.31\n\nOpen file: O key\nChange skin: F1/F2 |
|
- | 24 | Play/Stop: Space or P key\nStart playing selected file: Enter |
|
- | 25 | Goto next/previous track: Ctrl + Left/Right |
|
21 | #include "..\lib\patterns\libimg_load_skin.h" |
26 | Change sound volume: Left/Right key\nMute: M key' -St\n" |
22 | 27 | ||
23 | scroll_bar scroll1 = { 5,200,398,44,0,2,115,15,0,0xeeeeee,0xBBBbbb,0xeeeeee,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1}; |
28 | scroll_bar scroll1 = { 5,200,398,44,0,2,115,15,0,0xeeeeee,0xBBBbbb,0xeeeeee,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1}; |
Line 24... | Line 29... | ||
24 | llist list; |
29 | llist list; |
Line 131... | Line 136... | ||
131 | if (list.MouseOver(mouse.x, mouse.y)) |
136 | if (list.MouseOver(mouse.x, mouse.y)) |
132 | { |
137 | { |
133 | if (mouse.vert) if (list.MouseScroll(mouse.vert)) DrawPlayList(); |
138 | if (mouse.vert) if (list.MouseScroll(mouse.vert)) DrawPlayList(); |
134 | if (mouse.dblclick) {current_playing_file_n=list.current; StartPlayingMp3();} |
139 | if (mouse.dblclick) {current_playing_file_n=list.current; StartPlayingMp3();} |
135 | if (mouse.down) && (mouse.key&MOUSE_LEFT) if (list.ProcessMouse(mouse.x, mouse.y)) DrawPlayList(); |
140 | if (mouse.down) && (mouse.key&MOUSE_LEFT) if (list.ProcessMouse(mouse.x, mouse.y)) DrawPlayList(); |
136 | if (mouse.down) && (mouse.key&MOUSE_RIGHT) NotifyAndBackFocus( |
141 | if (mouse.down) && (mouse.key&MOUSE_RIGHT) NotifyAndBackFocus(ABOUT_MESSAGE); |
137 | "'Pixies Player v1.3\n\nOpen file: O key\nChange skin: F1/F2\nPlay/Stop: Space or P key\nStart playing selected file: Enter\nChange sound volume: Left/Right key\nMute: M key' -St\n" |
- | |
138 | ); |
- | |
139 | } |
142 | } |
140 | //drag window - emulate windows header |
143 | //drag window - emulate windows header |
141 | if(mouse.key&MOUSE_LEFT) && (mouse.y |
144 | if(mouse.key&MOUSE_LEFT) && (mouse.y |
142 | { |
145 | { |
143 | tmp_x = mouse.x; |
146 | tmp_x = mouse.x; |
Line 187... | Line 190... | ||
187 | win_x_small = Form.left; |
190 | win_x_small = Form.left; |
188 | win_y_small = Form.top; |
191 | win_y_small = Form.top; |
189 | MoveSize(win_x_normal, win_y_normal, skin.w -1 ,skin.h + list.h); |
192 | MoveSize(win_x_normal, win_y_normal, skin.w -1 ,skin.h + list.h); |
190 | } |
193 | } |
191 | break; |
194 | break; |
192 | case BUTTON_PLAYBACK_PREV: |
195 | case BUTTON_PLAYBACK_PREV: _PLAY_PREVIOUS: |
193 | current_playing_file_n--; |
196 | current_playing_file_n--; |
194 | StartPlayingMp3(); |
197 | StartPlayingMp3(); |
195 | break; |
198 | break; |
196 | case BUTTON_PLAYBACK_NEXT: |
199 | case BUTTON_PLAYBACK_NEXT: _PLAY_NEXT: |
197 | current_playing_file_n++; |
200 | current_playing_file_n++; |
198 | StartPlayingMp3(); |
201 | StartPlayingMp3(); |
199 | break; |
202 | break; |
200 | case BUTTON_PLAYBACK_PLAY_PAUSE: |
203 | case BUTTON_PLAYBACK_PLAY_PAUSE: |
201 | PlayAndPauseClick(); |
204 | PlayAndPauseClick(); |
202 | break; |
205 | break; |
203 | } |
206 | } |
204 | break; |
207 | break; |
205 | case evKey: |
208 | case evKey: |
206 | GetKeys(); |
209 | GetKeys(); |
- | 210 | if (key_modifier&KEY_LCTRL) || (key_modifier&KEY_RCTRL) { |
|
- | 211 | if (key_scancode==SCAN_CODE_LEFT) goto _PLAY_PREVIOUS; |
|
- | 212 | if (key_scancode==SCAN_CODE_RIGHT) goto _PLAY_NEXT; |
|
- | 213 | break; |
|
- | 214 | } |
|
207 | if (key_scancode==024) { OpenDialog_start stdcall (#o_dialog); if (o_dialog.status==1) OpenFolder(#openfile_path); } |
215 | if (key_scancode==024) { OpenDialog_start stdcall (#o_dialog); if (o_dialog.status==1) OpenFolder(#openfile_path); } |
208 | if (key_scancode==059) SetColorThemeLight(); |
216 | if (key_scancode==059) SetColorThemeLight(); |
209 | if (key_scancode==060) SetColorThemeDark(); |
217 | if (key_scancode==060) SetColorThemeDark(); |
210 | if (key_scancode==SCAN_CODE_LEFT) RunProgram("@VOLUME", "-"); |
218 | if (key_scancode==SCAN_CODE_LEFT) RunProgram("@VOLUME", "-"); |
211 | if (key_scancode==SCAN_CODE_RIGHT) RunProgram("@VOLUME", "+"); |
219 | if (key_scancode==SCAN_CODE_RIGHT) RunProgram("@VOLUME", "+"); |