[Mplayer-cvslog] CVS: main/Gui/mplayer/gtk menu.c,1.9,1.10

Zoltan Ponekker pontscho at mplayerhq.hu
Mon Jun 3 17:06:35 CEST 2002


Update of /cvsroot/mplayer/main/Gui/mplayer/gtk
In directory mail:/var/tmp.root/cvs-serv7079/Gui/mplayer/gtk

Modified Files:
	menu.c 
Log Message:
add VCD support for GUI

Index: menu.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/gtk/menu.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- menu.c	22 Apr 2002 13:20:24 -0000	1.9
+++ menu.c	3 Jun 2002 15:06:32 -0000	1.10
@@ -254,6 +254,9 @@
 GtkWidget * DVDAudioLanguageMenu;
 GtkWidget * DVDSubtitleLanguageMenu;
 
+GtkWidget * VCDSubMenu;
+GtkWidget * VCDTitleMenu;
+
 GtkWidget * create_PopUpMenu( void )
 {
  GtkWidget * Menu = NULL;
@@ -266,7 +269,9 @@
   AddSeparator( Menu );
    SubMenu=AddSubMenu( Menu,MSGTR_MENU_Open );
     AddMenuItem( SubMenu,MSGTR_MENU_PlayFile"    ", evLoadPlay );
-    AddMenuItem( SubMenu,MSGTR_MENU_PlayVCD, evNone );
+#ifdef HAVE_VCD
+    AddMenuItem( SubMenu,MSGTR_MENU_PlayVCD, evPlayVCD );
+#endif
 #ifdef USE_DVDREAD
     AddMenuItem( SubMenu,MSGTR_MENU_PlayDVD, evPlayDVD );
 #endif
@@ -287,6 +292,26 @@
     AddMenuItem( SubMenu,MSGTR_MENU_NormalSize"      ", evNormalSize );
     AddMenuItem( SubMenu,MSGTR_MENU_DoubleSize, evDoubleSize );
     AddMenuItem( SubMenu,MSGTR_MENU_FullScreen, evFullScreen );
+#ifdef HAVE_VCD
+   VCDSubMenu=AddSubMenu( Menu,MSGTR_MENU_VCD );
+    AddMenuItem( VCDSubMenu,MSGTR_MENU_PlayDisc,evPlayVCD );
+    AddSeparator( VCDSubMenu );
+    VCDTitleMenu=AddSubMenu( VCDSubMenu,MSGTR_MENU_Titles );
+    if ( guiIntfStruct.VCDTracks ) 
+     {
+      char tmp[32]; int i;
+      for ( i=0;i < guiIntfStruct.VCDTracks;i++ )
+       {
+        sprintf( tmp,MSGTR_MENU_Title,i+1 );
+	AddMenuItem( VCDTitleMenu,tmp,( (i+1) << 16 ) + evSetVCDTrack );
+       }
+     }
+     else
+      {
+       MenuItem=AddMenuItem( VCDTitleMenu,MSGTR_MENU_None,evNone );
+       gtk_widget_set_sensitive( MenuItem,FALSE );
+      }
+#endif
 #ifdef USE_DVDREAD
    DVDSubMenu=AddSubMenu( Menu,MSGTR_MENU_DVD );
     AddMenuItem( DVDSubMenu,MSGTR_MENU_PlayDisc"    ", evPlayDVD );




More information about the MPlayer-cvslog mailing list