[maemo-commits] [maemo-commits] r15736 - in projects/haf/trunk/gtk+: . gtk
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Thu Jul 3 18:18:35 EEST 2008
- Previous message: [maemo-commits] r15735 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r15737 - in projects/haf/trunk/maemo-launcher: . debian
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: kris Date: 2008-07-03 18:18:29 +0300 (Thu, 03 Jul 2008) New Revision: 15736 Modified: projects/haf/trunk/gtk+/ChangeLog projects/haf/trunk/gtk+/gtk/gtktreeview.c Log: 2008-07-03 Kristian Rietveld <kris at imendio.com> * gtk/gtktreeview.c (gtk_tree_view_button_release): in diablo mode, do not verify whether or not to active against the cursor row reference, rather against the current node under the cursor. Modified: projects/haf/trunk/gtk+/ChangeLog =================================================================== --- projects/haf/trunk/gtk+/ChangeLog 2008-07-03 15:00:02 UTC (rev 15735) +++ projects/haf/trunk/gtk+/ChangeLog 2008-07-03 15:18:29 UTC (rev 15736) @@ -1,5 +1,11 @@ 2008-07-03 Kristian Rietveld <kris at imendio.com> + * gtk/gtktreeview.c (gtk_tree_view_button_release): in diablo + mode, do not verify whether or not to active against the cursor + row reference, rather against the current node under the cursor. + +2008-07-03 Kristian Rietveld <kris at imendio.com> + * gtk/gtktreeview.c (gtk_tree_view_button_release): call free_queued_select_row() for both modes; no longer needed to call this before the other operations for fremantle mode, removed Modified: projects/haf/trunk/gtk+/gtk/gtktreeview.c =================================================================== --- projects/haf/trunk/gtk+/gtk/gtktreeview.c 2008-07-03 15:00:02 UTC (rev 15735) +++ projects/haf/trunk/gtk+/gtk/gtktreeview.c 2008-07-03 15:18:29 UTC (rev 15736) @@ -3374,19 +3374,27 @@ gtk_tree_view_row_activated (tree_view, path, tree_view->priv->focus_column); } - else if (gtk_tree_row_reference_valid (tree_view->priv->cursor)) + else if (mode == HILDON_DIABLO) { - GtkTreePath *cursor_path; + gint new_y; + GtkRBTree *tree, *activate_tree; + GtkRBNode *node, *activate_node; - cursor_path = gtk_tree_row_reference_get_path (tree_view->priv->cursor); + /* Get the node that is currently under the cursor */ + new_y = TREE_WINDOW_Y_TO_RBTREE_Y (tree_view, event->y); + if (new_y < 0) + new_y = 0; + _gtk_rbtree_find_offset (tree_view->priv->tree, new_y, &tree, &node); - if (!gtk_tree_path_compare (cursor_path, path)) + _gtk_tree_view_find_node (tree_view, path, + &activate_tree, &activate_node); + + /* Only emit activated if these match */ + if (tree == activate_tree && node == activate_node) { - gtk_tree_view_row_activated (tree_view, cursor_path, + gtk_tree_view_row_activated (tree_view, path, tree_view->priv->focus_column); } - - gtk_tree_path_free (cursor_path); } gtk_tree_path_free (path);
- Previous message: [maemo-commits] r15735 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r15737 - in projects/haf/trunk/maemo-launcher: . debian
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]