Browse Source

UI: Fix scene item edit drag & drop bug

If an user exits the source tree edit mode, without changing the name,
the scene item would become undraggable until the scene is refreshed.
We were setting the focus to just the label, not the whole widget.
cg2121 2 years ago
parent
commit
7a838e877f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      UI/source-tree.cpp

+ 1 - 1
UI/source-tree.cpp

@@ -413,7 +413,7 @@ void SourceTreeItem::ExitEditModeInternal(bool save)
 	editor = nullptr;
 	setFocusPolicy(Qt::NoFocus);
 	boxLayout->insertWidget(index, label);
-	label->setFocus();
+	setFocus();
 
 	/* ----------------------------------------- */
 	/* check for empty string                    */