After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 586487 - Binding for *_get_tooltip_context are wrong
Binding for *_get_tooltip_context are wrong
Status: RESOLVED FIXED
Product: vala
Classification: Core
Component: Bindings
0.7.x
Other All
: Normal major
: ---
Assigned To: Vala maintainers
Vala maintainers
Depends on:
Blocks:
 
 
Reported: 2009-06-20 19:26 UTC by Qball Cow
Modified: 2009-06-21 11:26 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Qball Cow 2009-06-20 19:26:25 UTC
Please describe the problem:
The x, y params should be of the type "out" 

get_tooltip_context (int x, int y, bool keyboard_tip, out unowned Gtk.TreeModel model, out unowned Gtk.TreePath path, out Gtk.TreeIter iter)

Should be:
get_tooltip_context (out int x,out int y, bool keyboard_tip, out unowned Gtk.TreeModel model, out unowned Gtk.TreePath path, out Gtk.TreeIter iter)

This for both GtkTreeView as GtkIconView.

(this is the gtk doc:
gboolean            gtk_tree_view_get_tooltip_context   (GtkTreeView *tree_view,
                                                         gint *x,
                                                         gint *y,
                                                         gboolean keyboard_tip,
                                                         GtkTreeModel **model,
                                                         GtkTreePath **path,
                                                         GtkTreeIter *iter);
This function is supposed to be used in a "query-tooltip" signal handler for GtkTreeView. The x, y and keyboard_tip values which are received in the signal handler, should be passed to this function without modification.

The return value indicates whether there is a tree view row at the given coordinates (TRUE) or not (FALSE) for mouse tooltips. For keyboard tooltips the row returned will be the cursor row. When TRUE, then any of model, path and iter which have been provided will be set to point to that row and the corresponding model. x and y will always be converted to be relative to tree_view's bin_window if keyboard_tooltip is FALSE.

tree_view :

a GtkTreeView
x :

the x coordinate (relative to widget coordinates)
y :

the y coordinate (relative to widget coordinates)
keyboard_tip :

whether this is a keyboard tooltip or not
model :

a pointer to receive a GtkTreeModel or NULL
path :

a pointer to receive a GtkTreePath or NULL
iter :

a pointer to receive a GtkTreeIter or NULL
Returns :

whether or not the given tooltip context points to a row.
)

Steps to reproduce:
1. 
2. 
3. 


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Jaap A. Haitsma 2009-06-21 11:26:57 UTC
Fixed

commit cd3780c2f1427dc7b51b3cf966790e74a43936c6
Author: Jaap A. Haitsma <jaap@haitsma.org>
Date:   Sun Jun 21 13:04:51 2009 +0200

    x, y are output parameter in get_tooltip_context methods
    
    Fixes bug #586487