From 1d8782915e6ba6dcd26a5a63283fe4e627425fc6 Mon Sep 17 00:00:00 2001 From: Jehan Date: Mon, 9 Oct 2023 15:59:13 +0200 Subject: [PATCH] Issue #10143: shift selecting is failing to highlight selected layers. This is a consequence of commit 98f0c448. Apparently setting the tree view cursor also reset visually the selection. So I make sure I only set the cursor on the first path in the list of selected items. --- app/widgets/gimpcontainertreeview.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/widgets/gimpcontainertreeview.c b/app/widgets/gimpcontainertreeview.c index b6bda663a1..1d93865fe1 100644 --- a/app/widgets/gimpcontainertreeview.c +++ b/app/widgets/gimpcontainertreeview.c @@ -934,7 +934,8 @@ gimp_container_tree_view_select_items (GimpContainerView *view, /* Add to the selection. */ gtk_tree_selection_select_path (tree_view->priv->selection, path->data); - gtk_tree_view_set_cursor (tree_view->view, path->data, NULL, FALSE); + if (path == paths) + gtk_tree_view_set_cursor (tree_view->view, path->data, NULL, FALSE); } g_signal_handlers_unblock_by_func (tree_view->priv->selection, gimp_container_tree_view_selection_changed,