Ignore GrabBroken events which are caused by overgrabbing inside the

2005-06-27  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtkmenushell.c (gtk_menu_shell_grab_broken): Ignore
	GrabBroken events which are caused by overgrabbing inside
	the application; menus rely on these for their operation.

	* gdk/gdkevents.h (struct _GdkEventGrabBroken): Add a
	grab_window field.

	* gdk/win32/gdkevents-win32.c (gdk_event_translate): Set
	grab_window to NULL when generating GrabBroken events for
	WM_KILLFOCUS messages.

	* gdk/x11/gdkmain-x11.c (_gdk_xgrab_check_unmap)
	(_gdk_xgrab_check_destroy): Set grab_window to NULL when
	generating GrabBroken events when the grab window becomes
	unviewable or is destroyed.

	* gdk/x11/gdkmain-x11.c (gdk_pointer_grab, gdk_keyboard_grab):
	Generate GrabBroken events when overriding a grab inside
	the application. In this case, set grab_window to the new
	grab_window.
This commit is contained in:
Matthias Clasen
2005-06-27 21:06:33 +00:00
committed by Matthias Clasen
parent f49eab1248
commit b2343762b1
9 changed files with 114 additions and 31 deletions

View File

@ -436,6 +436,7 @@ struct _GdkEventGrabBroken {
GdkWindow *window;
gint8 send_event;
gboolean keyboard;
GdkWindow *grab_window;
};
/* Event types for DND */