Commit 6350f58c authored by Carlos Garnacho's avatar Carlos Garnacho
Browse files

treeview: update to gesture widget-level API changes

parent c4a39f5a
......@@ -1842,9 +1842,8 @@ gtk_tree_view_init (GtkTreeView *tree_view)
gtk_gesture_single_set_touch_only (GTK_GESTURE_SINGLE (tree_view->priv->multipress_gesture), FALSE);
g_signal_connect (tree_view->priv->multipress_gesture, "pressed",
G_CALLBACK (_tree_view_multipress_pressed), tree_view);
gtk_widget_add_gesture (GTK_WIDGET (tree_view),
tree_view->priv->multipress_gesture,
GTK_PHASE_BUBBLE);
gtk_widget_add_controller (GTK_WIDGET (tree_view),
GTK_EVENT_CONTROLLER (tree_view->priv->multipress_gesture));
}
......@@ -2209,6 +2208,13 @@ gtk_tree_view_destroy (GtkWidget *widget)
_gtk_pixel_cache_free (tree_view->priv->pixel_cache);
tree_view->priv->pixel_cache = NULL;
if (tree_view->priv->multipress_gesture)
{
gtk_widget_remove_controller (GTK_WIDGET (tree_view),
GTK_EVENT_CONTROLLER (tree_view->priv->multipress_gesture));
g_clear_object (&tree_view->priv->multipress_gesture);
}
GTK_WIDGET_CLASS (gtk_tree_view_parent_class)->destroy (widget);
}
......
Supports Markdown
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