Re: Ximian bug #14205 - gnome-spell-0.4-ximian.1 doesn't work with RC1 Evolution
- From: Federico Mena Quintero <federico ximian com>
- To: michael ximian com
- Cc: evolution-patches ximian com, gnome-components-list gnome org
- Subject: Re: Ximian bug #14205 - gnome-spell-0.4-ximian.1 doesn't work with RC1 Evolution
- Date: 12 Nov 2001 07:55:44 -0600
On Thu, 2001-11-08 at 16:28, Federico Mena Quintero wrote:
> See the ChangeLog bits for an explanation of the bug.
>
> Is this OK to commit?
I think this may have slipped through the cracks. The bug was marked as
fixed and what was committed to Bonobo lacks the test for
GTK_WIDGET_MAPPED. Functionally both patches will do the same thing,
but what is on CVS right now *will* get an X error in the situation that
the bug describes.
I'd prefer using GTK_WIDGET_MAPPED for correctness and the gdk X error
trap as a precautionary measure against the WM unmapping one of its
frames instead of your own toplevel window.
Federico
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/bonobo/ChangeLog,v
retrieving revision 1.1141
diff -u -r1.1141 ChangeLog
--- ChangeLog 2001/11/07 02:17:14 1.1141
+++ ChangeLog 2001/11/08 22:22:52
@@ -1,3 +1,11 @@
+2001-11-08 Federico Mena Quintero <federico ximian com>
+
+ * bonobo/bonobo-socket.c (bonobo_socket_focus_out_event): Only
+ XSetInputFocus() if the toplevel is mapped. And even though we
+ make the check, push an error trap in case any of the toplevel's
+ ancestors, namely the window manager frame, is not mapped. Fixes
+ Ximian bug #14205.
+
2001-11-07 Michael Meeks <michael ximian com>
* Version 1.0.15
Index: bonobo/bonobo-socket.c
===================================================================
RCS file: /cvs/gnome/bonobo/bonobo/bonobo-socket.c,v
retrieving revision 1.20
diff -u -r1.20 bonobo-socket.c
--- bonobo/bonobo-socket.c 2001/10/10 02:20:58 1.20
+++ bonobo/bonobo-socket.c 2001/11/08 22:22:54
@@ -521,10 +521,19 @@
toplevel = gtk_widget_get_ancestor (widget, GTK_TYPE_WINDOW);
- if (toplevel)
+ if (toplevel && GTK_WIDGET_MAPPED (toplevel)) {
+ /* XSetInputFocus() will BadMatch if the window is not viewable;
+ * that is why we put the test for MAPPED above. Still, any of
+ * its ancestors, namely the window manager frame, may not be
+ * mapped, so we push an error trap anyways.
+ */
+ gdk_error_trap_push ();
XSetInputFocus (GDK_DISPLAY (),
GDK_WINDOW_XWINDOW (toplevel->window),
RevertToParent, CurrentTime);
+ gdk_flush ();
+ gdk_error_trap_pop ();
+ }
priv->gave_focus = FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]