aboutsummaryrefslogtreecommitdiffstats
path: root/src/screen_utils.c
diff options
context:
space:
mode:
authorKalle Wallin <kaw@linux.se>2004-07-03 13:02:42 +0000
committerKalle Wallin <kaw@linux.se>2004-07-03 13:02:42 +0000
commitbb2b7a65ed6ce964527e07843ec0ed86f0b45220 (patch)
tree3b133cd621de0f9e72acf3628cab73c32da54fa8 /src/screen_utils.c
parentb268b9992faa303d6283c5a88ba460b5fd73cef6 (diff)
downloadmpd-bb2b7a65ed6ce964527e07843ec0ed86f0b45220.tar.gz
mpd-bb2b7a65ed6ce964527e07843ec0ed86f0b45220.tar.xz
mpd-bb2b7a65ed6ce964527e07843ec0ed86f0b45220.zip
Ignore mouse events in wreadln, screen_getch
git-svn-id: https://svn.musicpd.org/ncmpc/trunk@1778 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to 'src/screen_utils.c')
-rw-r--r--src/screen_utils.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/screen_utils.c b/src/screen_utils.c
index c9abc7b1f..7e2ba146c 100644
--- a/src/screen_utils.c
+++ b/src/screen_utils.c
@@ -65,9 +65,17 @@ screen_getch(WINDOW *w, char *prompt)
while( (key=wgetch(w)) == ERR )
;
-
+
+#ifdef HAVE_GETMOUSE
+ /* ignore mouse events */
+ if( key==KEY_MOUSE )
+ return screen_getch(w, prompt);
+#endif
+
if( key==KEY_RESIZE )
- screen_resize();
+ {
+ screen_resize();
+ }
noecho();
curs_set(0);