File indexing completed on 2025-02-16 04:56:04
0001 /* 0002 SPDX-FileCopyrightText: 2013-2024 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 #pragma once 0007 0008 #include <KPixmapSequence> 0009 #include <QObject> 0010 class QTimer; 0011 namespace KSieveUi 0012 { 0013 class SieveEditorLoadProgressIndicator : public QObject 0014 { 0015 Q_OBJECT 0016 public: 0017 explicit SieveEditorLoadProgressIndicator(QObject *parent = nullptr); 0018 ~SieveEditorLoadProgressIndicator() override; 0019 0020 void startAnimation(); 0021 void stopAnimation(bool success); 0022 0023 Q_SIGNALS: 0024 void pixmapChanged(const QPixmap &); 0025 void loadFinished(bool success); 0026 0027 private: 0028 Q_DISABLE_COPY(SieveEditorLoadProgressIndicator) 0029 void slotTimerDone(); 0030 int mProgressCount = 0; 0031 KPixmapSequence mProgressPix; 0032 QTimer *const mProgressTimer; 0033 }; 0034 }