From e77baf064b17e3371b46a82b6656b5f73588df11 Mon Sep 17 00:00:00 2001 From: Kai Uwe Broulik Date: Thu, 1 May 2025 19:01:23 +0200 Subject: [PATCH] [PATCH] DeleteOrTrashJob: Add started signal It's emitted when the user has confirmed emptying trash and it will actually commence emptying it. Gbp-Pq: Name upstream_17cd1c9b_DeleteOrTrashJob-Add-started-signal.patch --- src/widgets/deleteortrashjob.cpp | 2 ++ src/widgets/deleteortrashjob.h | 11 +++++++++++ 2 files changed, 13 insertions(+) diff --git a/src/widgets/deleteortrashjob.cpp b/src/widgets/deleteortrashjob.cpp index 1f182c9..1af01a2 100644 --- a/src/widgets/deleteortrashjob.cpp +++ b/src/widgets/deleteortrashjob.cpp @@ -87,6 +87,8 @@ void DeleteOrTrashJobPrivate::slotAskUser(bool allowDelete, const QList &u // show the "File is too large to Trash" error message job->uiDelegate()->setAutoErrorHandlingEnabled(false); q->addSubjob(job); + + Q_EMIT q->started(); } } diff --git a/src/widgets/deleteortrashjob.h b/src/widgets/deleteortrashjob.h index 298e6f5..ef63285 100644 --- a/src/widgets/deleteortrashjob.h +++ b/src/widgets/deleteortrashjob.h @@ -68,6 +68,17 @@ public: */ void start() override; +Q_SIGNALS: + /** + * Emitted when the actual delete or trash job has been started. + * + * This can be used to display a busy indicator after the user has confirmed + * this operation. + * + * @since 6.15 + */ + void started(); + private: void slotResult(KJob *job) override; -- 2.30.2