From 777d52a167be2126527cc582225d89fbd5ca9032 Mon Sep 17 00:00:00 2001 From: WarmUpTill Date: Thu, 4 Jan 2024 00:44:31 +0100 Subject: [PATCH] Fix scene item name conflict selection not being visible For example, this could happen when the widget was initially created and SetSceneItem() was called, since currentSelection was still not set --- src/utils/scene-item-selection.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/utils/scene-item-selection.cpp b/src/utils/scene-item-selection.cpp index 629b89f6..a915c03f 100644 --- a/src/utils/scene-item-selection.cpp +++ b/src/utils/scene-item-selection.cpp @@ -635,6 +635,8 @@ void SceneItemSelectionWidget::SetSceneItem(const SceneItemSelection &item) _pattern->setText(item._pattern); _regex->SetRegexConfig(item._regex); + _currentSelection = item; + SetNameConflictVisibility(); switch (item._nameConflictSelectionType) { @@ -651,7 +653,6 @@ void SceneItemSelectionWidget::SetSceneItem(const SceneItemSelection &item) _nameConflictIndex->setCurrentIndex(idx); break; } - _currentSelection = item; SetWidgetVisibility(); }