[Mplayer-cvslog] CVS: main/Gui/mplayer psignal.c,1.18,1.19 sw.h,1.20,1.21 widgets.c,1.12,1.13 widgets.h,1.8,1.9

Zoltan Ponekker pontscho at mplayer.dev.hu
Sun Nov 18 20:22:57 CET 2001


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

Modified Files:
	psignal.c sw.h widgets.c widgets.h 
Log Message:
fix middle menu hideing bug

Index: psignal.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/psignal.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- psignal.c	16 Nov 2001 23:17:52 -0000	1.18
+++ psignal.c	18 Nov 2001 19:22:54 -0000	1.19
@@ -128,7 +128,14 @@
         break;
    case evShowPopUpMenu:
         gtkShMem->popupmenu=evNone;
+	if ( gtkShMem->visiblepopupmenu ) gtk_widget_hide_on_delete( PopUpMenu );
+        PopUpMenu=create_PopUpMenu();
         gtk_menu_popup( GTK_MENU( PopUpMenu ),NULL,NULL,NULL,NULL,0,0 );
+	gtkShMem->visiblepopupmenu=1;
+	break;
+   case evHidePopUpMenu:
+        if ( gtkShMem->visiblepopupmenu ) gtk_widget_hide_on_delete( PopUpMenu );
+	gtkShMem->visiblepopupmenu=0;
 	break;
   }
  gtkShMem->message=0;

Index: sw.h
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/sw.h,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- sw.h	14 Nov 2001 16:05:33 -0000	1.20
+++ sw.h	18 Nov 2001 19:22:54 -0000	1.21
@@ -32,13 +32,15 @@
 
  mplMouseTimer=mplMouseTimerConst;
  wsVisibleMouse( &appMPlayer.subWindow,wsShowMouseCursor );
+ 
 
  switch( Button )
   {
    case wsPMMouseButton:
-        gtkSendMessage( evShowPopUpMenu );
-	break;
+          gtkSendMessage( evShowPopUpMenu );
+          break;
    case wsPRMouseButton:
+	  if ( gtkShMem->visiblepopupmenu ) gtkSendMessage( evHidePopUpMenu );
           mplShowMenu( RX,RY );
           msButton=wsPRMouseButton;
           break;
@@ -48,6 +50,7 @@
           break;
 // ---
    case wsPLMouseButton:
+	  if ( gtkShMem->visiblepopupmenu ) gtkSendMessage( evHidePopUpMenu );
           sx=X; sy=Y;
           msButton=wsPLMouseButton;
           mplSubMoved=0;

Index: widgets.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/widgets.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- widgets.c	16 Nov 2001 23:17:52 -0000	1.12
+++ widgets.c	18 Nov 2001 19:22:54 -0000	1.13
@@ -59,7 +59,7 @@
  FileSelect=create_FileSelect();
  MessageBox=create_MessageBox(0);
  Options=create_Options();
- PopUpMenu=create_PopUpMenu();
+// PopUpMenu=create_PopUpMenu();
 }
 
 // --- forked function

Index: widgets.h
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/widgets.h,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- widgets.h	16 Nov 2001 23:17:52 -0000	1.8
+++ widgets.h	18 Nov 2001 19:22:54 -0000	1.9
@@ -52,7 +52,9 @@
  gtkSkinStruct         sb;
  gtkVisibleStruct      vs;
  gtkOptionsStruct      op;
+ 
  int		       popupmenu;
+ int		       visiblepopupmenu;
 } gtkCommStruct;
 
 extern gtkCommStruct * gtkShMem;




More information about the MPlayer-cvslog mailing list