Commit 822b99ee authored by Cosimo Cecchi's avatar Cosimo Cecchi

list-view: make sure not to activate items while chaining up

The event activation is done entirely in our signal handler, and
row-activated should only be used for the typeahead search box.
parent 1988c7bc
......@@ -613,6 +613,13 @@ do_popup_menu (GtkWidget *widget, NautilusListView *view, GdkEventButton *event)
}
}
static void
row_activated_callback (GtkTreeView *treeview, GtkTreePath *path,
GtkTreeViewColumn *column, NautilusListView *view)
{
activate_selected_items (view);
}
static gboolean
button_press_callback (GtkWidget *widget, GdkEventButton *event, gpointer callback_data)
{
......@@ -769,7 +776,15 @@ button_press_callback (GtkWidget *widget, GdkEventButton *event, gpointer callba
}
if (call_parent) {
g_signal_handlers_block_by_func (tree_view,
row_activated_callback,
view);
tree_view_class->button_press_event (widget, event);
g_signal_handlers_unblock_by_func (tree_view,
row_activated_callback,
view);
} else if (gtk_tree_selection_path_is_selected (selection, path)) {
gtk_widget_grab_focus (widget);
}
......@@ -960,13 +975,6 @@ row_collapsed_callback (GtkTreeView *treeview, GtkTreeIter *iter, GtkTreePath *p
unload_data);
}
static void
row_activated_callback (GtkTreeView *treeview, GtkTreePath *path,
GtkTreeViewColumn *column, NautilusListView *view)
{
activate_selected_items (view);
}
static void
subdirectory_unloaded_callback (NautilusListModel *model,
NautilusDirectory *directory,
......
Markdown is supported
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