comparison gui/ui/actions.c @ 35430:2d55540614a9

Move uiProcessNextInPlaylist to the guiInfo structure. It's an information for GUI control and need not be a separate global variable. Additionally, rename it PlaylistNext to shorten the name.
author ib
date Fri, 30 Nov 2012 11:40:35 +0000
parents 3a9048421524
children 20c90da2ba0d
comparison
equal deleted inserted replaced
35429:3a9048421524 35430:2d55540614a9
37 #include "input/input.h" 37 #include "input/input.h"
38 #include "libmpcodecs/vd.h" 38 #include "libmpcodecs/vd.h"
39 #include "libvo/video_out.h" 39 #include "libvo/video_out.h"
40 #include "mp_core.h" 40 #include "mp_core.h"
41 41
42 int uiProcessNextInPlaylist = 1;
43
44 void uiFullScreen(void) 42 void uiFullScreen(void)
45 { 43 {
46 if (!guiInfo.VideoWindow) 44 if (!guiInfo.VideoWindow)
47 return; 45 return;
48 46
253 251
254 curr = listMgr(PLAYLIST_ITEM_GET_CURR, 0); 252 curr = listMgr(PLAYLIST_ITEM_GET_CURR, 0);
255 253
256 if (curr) { 254 if (curr) {
257 uiSetFileName(curr->path, curr->name, STREAMTYPE_FILE); 255 uiSetFileName(curr->path, curr->name, STREAMTYPE_FILE);
258 uiProcessNextInPlaylist = 0; 256 guiInfo.PlaylistNext = 0;
259 break; 257 break;
260 } 258 }
261 259
262 return; 260 return;
263 } 261 }
310 308
311 prev = listMgr(PLAYLIST_ITEM_GET_PREV, 0); 309 prev = listMgr(PLAYLIST_ITEM_GET_PREV, 0);
312 310
313 if (prev) { 311 if (prev) {
314 uiSetFileName(prev->path, prev->name, STREAMTYPE_FILE); 312 uiSetFileName(prev->path, prev->name, STREAMTYPE_FILE);
315 uiProcessNextInPlaylist = (guiInfo.Playing ? 0 : 1); 313 guiInfo.PlaylistNext = (guiInfo.Playing ? 0 : 1);
316 guiInfo.Track--; 314 guiInfo.Track--;
317 break; 315 break;
318 } 316 }
319 317
320 return; 318 return;
363 361
364 next = listMgr(PLAYLIST_ITEM_GET_NEXT, 0); 362 next = listMgr(PLAYLIST_ITEM_GET_NEXT, 0);
365 363
366 if (next) { 364 if (next) {
367 uiSetFileName(next->path, next->name, STREAMTYPE_FILE); 365 uiSetFileName(next->path, next->name, STREAMTYPE_FILE);
368 uiProcessNextInPlaylist = (guiInfo.Playing ? 0 : 1); 366 guiInfo.PlaylistNext = (guiInfo.Playing ? 0 : 1);
369 guiInfo.Track++; 367 guiInfo.Track++;
370 break; 368 break;
371 } 369 }
372 370
373 return; 371 return;