From e1fce66f38332eb0995b2a4847429e8a71808c9c Mon Sep 17 00:00:00 2001 From: Henning Gruendl Date: Mon, 5 Dec 2022 10:46:30 +0100 Subject: [PATCH] QmlDesigner: Remove unnecessary function Change-Id: I3a8c29ba7e24b10df957b4cb8fdb9f6e3acd6855 Reviewed-by: Thomas Hartmann --- share/qtcreator/qmldesigner/newstateseditor/Main.qml | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/share/qtcreator/qmldesigner/newstateseditor/Main.qml b/share/qtcreator/qmldesigner/newstateseditor/Main.qml index 74b50d5f94a..0176cc79f60 100644 --- a/share/qtcreator/qmldesigner/newstateseditor/Main.qml +++ b/share/qtcreator/qmldesigner/newstateseditor/Main.qml @@ -315,15 +315,8 @@ Rectangle { standardButtons: Dialog.Apply | Dialog.Cancel x: editButton.x - Math.max(0, editButton.x + editDialog.width - root.width) y: toolBar.height - closePolicy: Popup.NoAutoClose - width: Math.min(300, root.width) - - function apply() { - let renamed = statesEditorModel.renameActiveStateGroup(editTextField.text) - if (renamed) - editDialog.close() - } + closePolicy: Popup.NoAutoClose onApplied: editDialog.accept()