From 85ee40b4d5c573ed239214fc227611c7936c9c88 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Fri, 10 Feb 2012 09:08:03 +0100 Subject: [PATCH] gcr: Reenable grabs for password prompts * Disable them when configure is passed --enable-debug --- configure.ac | 1 + gcr/gcr-prompt-dialog.c | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/configure.ac b/configure.ac index be7f7fc..54a051e 100644 --- a/configure.ac +++ b/configure.ac @@ -201,6 +201,7 @@ fi if test "$enable_debug" = "yes"; then debug_status="yes (-g, -O0, debug output, testable)" + AC_DEFINE_UNQUOTED(GCR_DISABLE_GRABS, 1, [Disable grabs]) CFLAGS="$CFLAGS -O0" elif test "$enable_debug" = "no"; then debug_status="no (no debug output, not testable, G_DISABLE_ASSERT)" diff --git a/gcr/gcr-prompt-dialog.c b/gcr/gcr-prompt-dialog.c index c4691c5..9174904 100644 --- a/gcr/gcr-prompt-dialog.c +++ b/gcr/gcr-prompt-dialog.c @@ -56,7 +56,11 @@ * The class for #GcrPromptDialog. */ +#ifdef GCR_DISABLE_GRABS #define GRAB_KEYBOARD 0 +#else +#define GRAB_KEYBOARD 1 +#endif typedef enum { PROMPT_NONE, -- 2.7.4