File indexing completed on 2024-12-22 05:05:31
0001 /* 0002 SPDX-FileCopyrightText: 2015-2024 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: GPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include <QObject> 0010 #include <QStringList> 0011 0012 class QWidget; 0013 class QProgressDialog; 0014 class FullSynchronizeResourcesJob : public QObject 0015 { 0016 Q_OBJECT 0017 public: 0018 explicit FullSynchronizeResourcesJob(QObject *parent = nullptr); 0019 ~FullSynchronizeResourcesJob() override; 0020 0021 void setResources(const QStringList &lst); 0022 0023 void setWindowParent(QWidget *parent); 0024 0025 void start(); 0026 Q_SIGNALS: 0027 void synchronizeFinished(); 0028 void synchronizeInstanceDone(const QString &instance); 0029 void synchronizeInstanceFailed(const QString &instance); 0030 0031 private: 0032 void slotSynchronizeInstanceFailed(const QString &identifier); 0033 void slotSynchronizeInstanceDone(const QString &identifier); 0034 void slotSynchronizeFinished(); 0035 0036 QStringList mResources; 0037 QWidget *mWindowParent = nullptr; 0038 QProgressDialog *mProgressDialog = nullptr; 0039 };