Index: gnome-keyring-3.2.2/ui/gku-prompt-tool.c
===================================================================
--- gnome-keyring-3.2.2.orig/ui/gku-prompt-tool.c	2011-11-14 18:27:43.000000000 +0800
+++ gnome-keyring-3.2.2/ui/gku-prompt-tool.c	2012-04-03 15:45:40.338888289 +0800
@@ -201,9 +201,15 @@
 	    state & GDK_WINDOW_STATE_ICONIFIED ||
 	    state & GDK_WINDOW_STATE_FULLSCREEN ||
 	    state & GDK_WINDOW_STATE_MAXIMIZED)
+	{
+		g_object_set_data (G_OBJECT (win), "grab-disabled", GINT_TO_POINTER (1));
 		ungrab_keyboard (win, (GdkEvent*)event, data);
-	else
+	}
+	else if (g_object_get_data (G_OBJECT (win), "grab-disabled") == GPOINTER_TO_INT (1))
+	{
+		g_object_set_data (G_OBJECT (win), "grab-disabled", GINT_TO_POINTER (0));
 		grab_keyboard (win, (GdkEvent*)event, data);
+	}
 
 	return FALSE;
 }
@@ -465,6 +471,7 @@
 	 * When passwords are involved we grab the keyboard so that people
 	 * don't accidentally type their passwords in other windows.
 	 */
+	g_object_set_data (G_OBJECT (dialog), "grab-disabled", GINT_TO_POINTER (0));
 	g_signal_connect (dialog, "map-event", G_CALLBACK (grab_keyboard), NULL);
 	g_signal_connect (dialog, "unmap-event", G_CALLBACK (ungrab_keyboard), NULL);
 	g_signal_connect (dialog, "window-state-event", G_CALLBACK (window_state_changed), NULL);
