[MPlayer-cvslog] r34162 - in trunk/gui: interface.c ui/actions.c
ib
subversion at mplayerhq.hu
Fri Sep 30 16:33:13 CEST 2011
Author: ib
Date: Fri Sep 30 16:33:13 2011
New Revision: 34162
Log:
Set all buttons related to seek operations according to stream type.
Setting just evSetMoviePosition isn't enough.
The check in uiAbsSeek() isn't necessary, because the related button
and event are disabled anyway.
Modified:
trunk/gui/interface.c
trunk/gui/ui/actions.c
Modified: trunk/gui/interface.c
==============================================================================
--- trunk/gui/interface.c Fri Sep 30 16:18:26 2011 (r34161)
+++ trunk/gui/interface.c Fri Sep 30 16:33:13 2011 (r34162)
@@ -323,6 +323,7 @@ int gui(int what, void *data)
dvd_priv_t *dvd;
#endif
plItem *next;
+ int state;
if (guiInfo.mpcontext)
mixer = mpctx_get_mixer(guiInfo.mpcontext);
@@ -641,10 +642,14 @@ int gui(int what, void *data)
guiInfo.sh_video = data;
- if (guiInfo.StreamType == STREAMTYPE_STREAM)
- btnSet(evSetMoviePosition, btnDisabled);
- else
- btnSet(evSetMoviePosition, btnReleased);
+ state = (guiInfo.StreamType == STREAMTYPE_STREAM ? btnDisabled : btnReleased);
+ btnSet(evForward10sec, state);
+ btnSet(evBackward10sec, state);
+ btnSet(evForward1min, state);
+ btnSet(evBackward1min, state);
+ btnSet(evForward10min, state);
+ btnSet(evBackward10min, state);
+ btnSet(evSetMoviePosition, state);
#ifdef CONFIG_DXR3
if (video_driver_list && !gstrcmp(video_driver_list[0], "dxr3") && (((demuxer_t *)mpctx_get_demuxer(guiInfo.mpcontext))->file_format != DEMUXER_TYPE_MPEG_PS) && !gtkVfLAVC) {
Modified: trunk/gui/ui/actions.c
==============================================================================
--- trunk/gui/ui/actions.c Fri Sep 30 16:18:26 2011 (r34161)
+++ trunk/gui/ui/actions.c Fri Sep 30 16:33:13 2011 (r34162)
@@ -112,9 +112,6 @@ void uiRelSeek(float sec)
void uiAbsSeek(float percent)
{
- if (guiInfo.StreamType == STREAMTYPE_STREAM)
- return;
-
rel_seek_secs = percent / 100.0;
abs_seek_pos = 3;
}
More information about the MPlayer-cvslog
mailing list