From 59be9e98bfd1bd35fa6944d87c0a0013f7c427d8 Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Thu, 23 Mar 2023 12:52:44 +0100 Subject: [PATCH] Debugger: Avoid duplicate commit and close The delegate triggers a commit and close already when the focus is switched. So, the additional calls will end up in a warning deep inside QAbstractItemView and not processed. Get rid of the obsolete calls and the warnings. Change-Id: Ic27f6b1aa0b73f4bb82b0878650d8ae8ae8f87d2 Reviewed-by: hjk --- src/plugins/debugger/console/consoleitemdelegate.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/plugins/debugger/console/consoleitemdelegate.cpp b/src/plugins/debugger/console/consoleitemdelegate.cpp index 20177bd46ec..8f76704b703 100644 --- a/src/plugins/debugger/console/consoleitemdelegate.cpp +++ b/src/plugins/debugger/console/consoleitemdelegate.cpp @@ -241,11 +241,6 @@ QWidget *ConsoleItemDelegate::createEditor(QWidget *parent, "margin-top: 4px;" "background-color: transparent;" "}"); - connect(editor, &ConsoleEdit::editingFinished, this, [this, editor] { - auto delegate = const_cast(this); - emit delegate->commitData(editor); - emit delegate->closeEditor(editor); - }); return editor; }