* select.cc (peek_console): Don't report read_ready on mouse events unless we
are looking for mouse events. * fhandler.h (fhandler_console::mouse_aware): New method.
This commit is contained in:
		| @@ -1,3 +1,9 @@ | |||||||
|  | Thu Mar  1 20:48:11 2001  Christopher Faylor <cgf@cygnus.com> | ||||||
|  |  | ||||||
|  | 	* select.cc (peek_console): Don't report read_ready on mouse events | ||||||
|  | 	unless we are looking for mouse events. | ||||||
|  | 	* fhandler.h (fhandler_console::mouse_aware): New method. | ||||||
|  |  | ||||||
| Wed Feb 28 15:10:00 2001  Corinna Vinschen <corinna@vinschen.de> | Wed Feb 28 15:10:00 2001  Corinna Vinschen <corinna@vinschen.de> | ||||||
|  |  | ||||||
| 	* uinfo.cc: Eliminate `#include <wchar.h>'. | 	* uinfo.cc: Eliminate `#include <wchar.h>'. | ||||||
|   | |||||||
| @@ -680,6 +680,7 @@ public: | |||||||
|  |  | ||||||
|   int ioctl (unsigned int cmd, void *); |   int ioctl (unsigned int cmd, void *); | ||||||
|   void init (HANDLE, DWORD, mode_t); |   void init (HANDLE, DWORD, mode_t); | ||||||
|  |   bool mouse_aware () {return use_mouse;} | ||||||
|  |  | ||||||
|   select_record *select_read (select_record *s); |   select_record *select_read (select_record *s); | ||||||
|   select_record *select_write (select_record *s); |   select_record *select_write (select_record *s); | ||||||
|   | |||||||
| @@ -638,7 +638,10 @@ peek_console (select_record *me, int ignra) | |||||||
| 	else if (irec.EventType == MOUSE_EVENT && | 	else if (irec.EventType == MOUSE_EVENT && | ||||||
| 		 (irec.Event.MouseEvent.dwEventFlags == 0 || | 		 (irec.Event.MouseEvent.dwEventFlags == 0 || | ||||||
| 		  irec.Event.MouseEvent.dwEventFlags == DOUBLE_CLICK)) | 		  irec.Event.MouseEvent.dwEventFlags == DOUBLE_CLICK)) | ||||||
|  | 	  { | ||||||
|  | 	    if (fh->mouse_aware ()) | ||||||
| 	      return me->read_ready = 1; | 	      return me->read_ready = 1; | ||||||
|  | 	  } | ||||||
| 	else if (irec.EventType == KEY_EVENT && irec.Event.KeyEvent.bKeyDown == TRUE && | 	else if (irec.EventType == KEY_EVENT && irec.Event.KeyEvent.bKeyDown == TRUE && | ||||||
| 		 (irec.Event.KeyEvent.uChar.AsciiChar || get_nonascii_key (irec, tmpbuf))) | 		 (irec.Event.KeyEvent.uChar.AsciiChar || get_nonascii_key (irec, tmpbuf))) | ||||||
| 	  return me->read_ready = 1; | 	  return me->read_ready = 1; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user