check if the pointer is really over the returned widget, since the

2007-07-16  Kristian Rietveld  <kris@imendio.com>

	* gtk/gtktooltip.c (find_topmost_widget_coords_from_event): check
	if the pointer is really over the returned widget, since the
	coordinate check may not always be hit in find_widget_under_pointer().


svn path=/trunk/; revision=18478
This commit is contained in:
Kristian Rietveld
2007-07-16 16:39:53 +00:00
committed by Kristian Rietveld
parent ed339f27f8
commit 50a0d3b8eb
2 changed files with 11 additions and 0 deletions

View File

@@ -1,3 +1,9 @@
2007-07-16 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_topmost_widget_coords_from_event): check
if the pointer is really over the returned widget, since the
coordinate check may not always be hit in find_widget_under_pointer().
2007-07-16 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkfilechooserbutton.c (model_add_special_get_info_cb):

View File

@@ -593,6 +593,11 @@ find_topmost_widget_coords_from_event (GdkEvent *event,
tmp = find_widget_under_pointer (event->any.window, &tx, &ty);
/* Make sure the pointer can actually be on the widget returned */
if (tx < 0 || tx >= tmp->allocation.width ||
ty < 0 || ty >= tmp->allocation.height)
return NULL;
if (x)
*x = tx;
if (y)