From 1eb387c2baac583881b62596277785923b9b749b Mon Sep 17 00:00:00 2001 From: David Redondo Date: Mon, 25 Jan 2021 12:26:29 +0100 Subject: [PATCH] [PATCH] Fix lockup when renaming a file from properties dialog 4c12899369f43009269d0fdb80964483365bb922 changed how we show the rename dialog. Before we would exec() it and now we call show(). This causes a lockup when renaming a file from the properties dialog to a filename that already exsist. Optimally we would change KPropertiesDialog to make it async and not use nested event loops but this fixes the lockup for now. . BUG:431902 Gbp-Pq: Name upstream_5.79_0300441bb80c3d75a305bc7b1f4a7e1c36f28845_fix_lockup_when_renaming_a_file_from_properties_dialog.patch --- src/widgets/kpropertiesdialog.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/widgets/kpropertiesdialog.cpp b/src/widgets/kpropertiesdialog.cpp index a7c52d5..cbd5afc 100644 --- a/src/widgets/kpropertiesdialog.cpp +++ b/src/widgets/kpropertiesdialog.cpp @@ -1538,7 +1538,7 @@ void KFilePropsPlugin::applyChanges() } else { // Copying a template job = KIO::copyAs(oldurl, properties->url()); } - + KJobWidgets::setWindow(job, properties); connect(job, &KJob::result, this, &KFilePropsPlugin::slotCopyFinished); connect(job, &KIO::CopyJob::renamed, @@ -1547,7 +1547,7 @@ void KFilePropsPlugin::applyChanges() QEventLoop eventLoop; connect(this, &KFilePropsPlugin::leaveModality, &eventLoop, &QEventLoop::quit); - eventLoop.exec(QEventLoop::ExcludeUserInputEvents); + eventLoop.exec(); return; } properties->updateUrl(properties->url()); -- 2.30.2