Commit 4995ea0f authored by Matthias Clasen's avatar Matthias Clasen

Set the root coordinates in the event correctly. Patch by Kristian

        * gtk/gtktooltip.c (gtk_tooltip_trigger_query): Set the root
        coordinates in the event correctly. Patch by Kristian Rietveld.


svn path=/trunk/; revision=22277
parent 7fd058b6
2009-02-03 Matthias Clasen <mclasen@redhat.com>
Bug 538439 – tooltip may appear in upper left corner instead of
over widget
* gtk/gtktooltip.c (gtk_tooltip_trigger_query): Set the root
coordinates in the event correctly. Patch by Kristian Rietveld.
2009-02-02 Matthias Clasen <mclasen@redhat.com>
* configure.in: Bump version
......
......@@ -440,6 +440,10 @@ gtk_tooltip_trigger_tooltip_query (GdkDisplay *display)
event.motion.y = y;
event.motion.is_hint = FALSE;
gdk_window_get_origin (window, &x, &y);
event.motion.x_root = event.motion.x + x;
event.motion.y_root = event.motion.y + y;
_gtk_tooltip_handle_event (&event);
}
......@@ -518,6 +522,9 @@ child_location_foreach (GtkWidget *child,
if (!GTK_WIDGET_DRAWABLE (child))
return;
x = 0;
y = 0;
/* (child_loc->x, child_loc->y) are relative to
* child_loc->container's allocation.
*/
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment