From 0f75aa69ea5cd448553d80fc20b172ee5eb28092 Mon Sep 17 00:00:00 2001 From: Akseli Lahtinen Date: Wed, 23 Apr 2025 15:39:36 +0300 Subject: [PATCH] DolphinView: If contextmenu is requested, abort twoClicksRenaming When using single click to select, user can double click the file to start renaming it. If user at the same time also opens context menu, user can delete the file while the renaming prompt is open, which causes weirdness. This patch makes sure we abort the double click renaming when context menu is requested. BUG: 503185 --- src/views/dolphinview.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/views/dolphinview.cpp b/src/views/dolphinview.cpp index d5908a081..f3bde88df 100644 --- a/src/views/dolphinview.cpp +++ b/src/views/dolphinview.cpp @@ -1174,6 +1174,9 @@ void DolphinView::slotItemContextMenuRequested(int index, const QPointF &pos) if (m_selectionChangedTimer->isActive()) { emitSelectionChangedSignal(); } + if (m_twoClicksRenamingTimer->isActive()) { + abortTwoClicksRenaming(); + } const KFileItem item = m_model->fileItem(index); Q_EMIT requestContextMenu(pos.toPoint(), item, selectedItems(), url()); -- 2.47.3