File indexing completed on 2024-05-12 05:25:36
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 <QCommandLineParser> 0010 #include <QObject> 0011 0012 class QApplication; 0013 class PimDataExporterWindow; 0014 class PimDataCommandLineOption : public QObject 0015 { 0016 Q_OBJECT 0017 public: 0018 explicit PimDataCommandLineOption(QObject *parent = nullptr); 0019 ~PimDataCommandLineOption() override; 0020 0021 void createParser(const QApplication &app); 0022 void setExportWindow(PimDataExporterWindow *exporterWindow); 0023 void handleCommandLine(); 0024 0025 [[nodiscard]] bool parseUserFeedback() const; 0026 0027 public Q_SLOTS: 0028 void slotActivateRequested(const QStringList &arguments, const QString &workingDirectory); 0029 0030 private: 0031 QCommandLineParser mParser; 0032 PimDataExporterWindow *mExporterWindow = nullptr; 0033 };