[MPlayer-cvslog] r38029 - trunk/gui/dialog/menu.c
ib
subversion at mplayerhq.hu
Tue Apr 3 14:48:42 EEST 2018
Author: ib
Date: Tue Apr 3 14:48:42 2018
New Revision: 38029
Log:
Move menu item "Video tracks".
Remove it from the group of audio menu items and
place it at the end of the group of video menu items.
Modified:
trunk/gui/dialog/menu.c
Modified: trunk/gui/dialog/menu.c
==============================================================================
--- trunk/gui/dialog/menu.c Tue Apr 3 14:33:43 2018 (r38028)
+++ trunk/gui/dialog/menu.c Tue Apr 3 14:48:42 2018 (r38029)
@@ -731,6 +731,28 @@ GtkWidget * CreatePopUpMenu( void )
}
}
+ if ( guiInfo.Playing && demuxer && guiInfo.StreamType != STREAMTYPE_DVD )
+ {
+ int i,c = 0;
+
+ for ( i=0;i < MAX_V_STREAMS;i++ )
+ if ( demuxer->v_streams[i] ) c++;
+
+ if ( c > 1 )
+ {
+ SubMenu=AddSubMenu( window1, (const char*)video_xpm, Menu,MSGTR_GUI_VideoTracks );
+ for ( i=0;i < MAX_V_STREAMS;i++ )
+ if ( demuxer->v_streams[i] )
+ {
+ int vid = ((sh_video_t *)demuxer->v_streams[i])->vid;
+ char tmp[32];
+ int selected_id = (video_id == vid || (video_id == -1 && vid == demuxer_default_video_track(demuxer)));
+ snprintf( tmp,32,MSGTR_GUI_TrackN,vid );
+ AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu,tmp,selected_id,( vid << 16 ) + ivSetVideo );
+ }
+ }
+ }
+
AddSeparator( Menu );
MenuItem=AddMenuCheckItem( window1, (const char*)sound_xpm, Menu,MSGTR_GUI_Mute,mixer->muted,evMute );
if ( !guiInfo.AudioChannels ) gtk_widget_set_sensitive( MenuItem,FALSE );
@@ -756,23 +778,6 @@ GtkWidget * CreatePopUpMenu( void )
AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu,tmp,selected_id,( aid << 16 ) + ivSetAudio );
}
}
-
- for ( c=0,i=0;i < MAX_V_STREAMS;i++ )
- if ( demuxer->v_streams[i] ) c++;
-
- if ( c > 1 )
- {
- SubMenu=AddSubMenu( window1, (const char*)video_xpm, Menu,MSGTR_GUI_VideoTracks );
- for ( i=0;i < MAX_V_STREAMS;i++ )
- if ( demuxer->v_streams[i] )
- {
- int vid = ((sh_video_t *)demuxer->v_streams[i])->vid;
- char tmp[32];
- int selected_id = (video_id == vid || (video_id == -1 && vid == demuxer_default_video_track(demuxer)));
- snprintf( tmp,32,MSGTR_GUI_TrackN,vid );
- AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu,tmp,selected_id,( vid << 16 ) + ivSetVideo );
- }
- }
}
/* cheap subtitle switching for non-DVD streams */
More information about the MPlayer-cvslog
mailing list