From 0e7009bcad9f192e88ffa5c9a28941f65a558053 Mon Sep 17 00:00:00 2001 From: Dave Davenport Date: Thu, 21 May 2015 23:53:28 +0200 Subject: [PATCH] Test fix for issue #167 --- include/textbox.h | 12 ++++++------ source/rofi.c | 8 ++++++++ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/include/textbox.h b/include/textbox.h index 6ec1cf7b..1fd2dc33 100644 --- a/include/textbox.h +++ b/include/textbox.h @@ -23,12 +23,12 @@ typedef struct typedef enum { - TB_AUTOHEIGHT = 1 << 0, - TB_AUTOWIDTH = 1 << 1, - TB_LEFT = 1 << 16, - TB_RIGHT = 1 << 17, - TB_CENTER = 1 << 18, - TB_EDITABLE = 1 << 19, + TB_AUTOHEIGHT = 1 << 0, + TB_AUTOWIDTH = 1 << 1, + TB_LEFT = 1 << 16, + TB_RIGHT = 1 << 17, + TB_CENTER = 1 << 18, + TB_EDITABLE = 1 << 19, } TextboxFlags; diff --git a/source/rofi.c b/source/rofi.c index dd632f0b..7752ce16 100644 --- a/source/rofi.c +++ b/source/rofi.c @@ -1304,6 +1304,14 @@ MenuReturn menu ( char **lines, unsigned int num_lines, char **input, char *prom } while ( XCheckTypedEvent ( display, KeyPress, &ev ) ); } } + // Wait for final release? + { + XEvent ev; + do { + XNextEvent ( display, &ev ); + } while ( ev.type != KeyRelease ); + } + // Update input string. g_free ( *input );