GNOME Bugzilla – Bug 114851
Cannot determine the widget for which tooltip is displayed
Last modified: 2011-02-04 16:12:26 UTC
When a tooltip is displayed it is not possible to determine from the tooltip window the widget whose tooltip is displayed.
Created attachment 17394 [details] [review] Proposed patch
Marking AP2 to reflect a11y team's assessment of a11y impact.
We *never* use object data as part of the public API
Apologies for spam... marking as GNOMEVER2.3 so it appears on the official GNOME bug list :)
I'd probably do this as a straightforward API like: gtk_tooltips_get_info_from_tip_window (GtkWindow *tip_window, GtkTooltips **tooltips, GtkWidget **current_widget);
Created attachment 21000 [details] [review] Updated patch
review of patch requested for gtk+ 2.4. This blocks implementation of a desirable and significant (but possibly non-essential) ATK/gail feature.
* Needs documentation, including a warning that this should not be used by applications. * Function needs a g_return_if_fail (GTK_IS_WINDOW (tip_window)) * The function segfaults if called on a window that isn't from GtkTooltips; since there's no way of finding out if a window is from GtkTooltips, this seems bad :-) I'd probably add a boolean return value with FALSE if the window isn't from GtkTooltips; in that case, though it's still nice to NULL out the two out parameters. * I don't like reusing the key like that, the name GtkTooltipsData is a specific reference to the GtkToolTipsData structure Otherwise, looks OK to me.
Ok, I went ahead and committed the patch with the changes outlined by owen, and with docs.