changeset 4835:1f59d4d73558

Fix my mistake (forgot to remove a getch2_enable) but in the rigth way this time, otherwise you can't interrupt network connection and cache filling from the keyboard
author albeu
date Sun, 24 Feb 2002 12:05:12 +0000
parents fdb92826250c
children f832f7bcf76b
files mplayer.c
diffstat 1 files changed, 6 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/mplayer.c	Sun Feb 24 11:23:48 2002 +0000
+++ b/mplayer.c	Sun Feb 24 12:05:12 2002 +0000
@@ -756,13 +756,12 @@
 
 play_next_file:
 
-// We can enable getch2 *either* here *or* on a per-file basis, but NOT both!!!
-// Doing it both places causes the saved terminal state to get trashed!!
-// Maybe this can be renabled at a later date if it's useful...
-//if(!use_stdin && !slave_mode){
-//  getch2_enable();  // prepare stdin for hotkeys...
-//  inited_flags|=INITED_GETCH2;
-//}
+// We must enable getch2 here to be able to interrupt network connection
+// or cache filling
+if(!use_stdin && !slave_mode){
+  getch2_enable();  // prepare stdin for hotkeys...
+  inited_flags|=INITED_GETCH2;
+}
 
 #ifdef HAVE_NEW_GUI
     if ( use_gui ) {
@@ -1555,11 +1554,6 @@
 
 mp_msg(MSGT_CPLAYER,MSGL_INFO,MSGTR_StartPlaying);fflush(stdout);
 
-if(!use_stdin && !slave_mode){
-  getch2_enable();  // prepare stdin for hotkeys...
-  inited_flags|=INITED_GETCH2;
-}
-
 InitTimer();
 
 total_time_usage_start=GetTimer();