[Mplayer-cvslog] CVS: main mplayer.c,1.268,1.269

Arpi of Ize arpi at mplayer.dev.hu
Sat Sep 1 00:58:44 CEST 2001


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

Modified Files:
	mplayer.c 
Log Message:
fixed interaction between commandlien and fileselector

Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.268
retrieving revision 1.269
diff -u -r1.268 -r1.269
--- mplayer.c	31 Aug 2001 22:35:04 -0000	1.268
+++ mplayer.c	31 Aug 2001 22:58:41 -0000	1.269
@@ -581,13 +581,13 @@
 
 #ifdef HAVE_NEW_GUI
     if ( use_gui ) {
-      if(filename) strcpy( mplShMem->Filename,filename );
+      if(filename && !mplShMem->FilenameChanged) strcpy( mplShMem->Filename,filename );
 //      mplShMem->Playing= (gui_no_filename) ? 0 : 1;
       while(mplShMem->Playing!=1){
 	usleep(20000);
 	EventHandling();
       }
-      if(gui_no_filename){
+      if(mplShMem->FilenameChanged){
         filename=mplShMem->Filename;
       }
     }
@@ -1494,6 +1494,7 @@
 #endif
 
   if(osd_function==OSD_PAUSE){
+      int gui_pause_flag=0; // gany!
       mp_msg(MSGT_CPLAYER,MSGL_STATUS,"\n------ PAUSED -------\r");fflush(stdout);
 #ifdef HAVE_NEW_GUI
       if(use_gui) mplShMem->Playing=2;
@@ -1511,7 +1512,8 @@
 #ifdef HAVE_NEW_GUI
              if(use_gui){
 		EventHandling();
-		if(mplShMem->Playing!=2 || (rel_seek_secs || abs_seek_pos)) break; // end of pause or seek
+		if(mplShMem->Playing!=2 || (rel_seek_secs || abs_seek_pos))
+		  { gui_pause_flag=1; break; } // end of pause or seek
              }
 #endif
              if(use_stdin) usec_sleep(1000); // do not eat the CPU
@@ -1520,7 +1522,7 @@
       if (audio_out && sh_audio)
         audio_out->resume();	// resume audio
 #ifdef HAVE_NEW_GUI
-      if(use_gui) if(mplShMem->Playing==2) mplShMem->Playing=1;
+      if(use_gui && !gui_pause_flag) mplShMem->Playing=1; // play from keyboard
 #endif
   }
 




More information about the MPlayer-cvslog mailing list