File indexing completed on 2024-04-28 16:43:21
0001 /* 0002 * This file is part of the KDE project 0003 * 0004 * SPDX-FileCopyrightText: 2015 David Rosca <nowrep@gmail.com> 0005 * 0006 * SPDX-License-Identifier: LGPL-2.0-or-later 0007 */ 0008 0009 #ifndef FAILPAGE_H 0010 #define FAILPAGE_H 0011 0012 #include "ui_failpage.h" 0013 0014 #include <optional> 0015 0016 #include <QWizardPage> 0017 0018 class SendFileWizard; 0019 0020 class FailPage : public QWizardPage, Ui::FailPage 0021 { 0022 Q_OBJECT 0023 0024 public: 0025 explicit FailPage(SendFileWizard *parent = nullptr); 0026 0027 void initializePage() override; 0028 0029 /** 0030 * If not set, \FailPage will use the error message from \SendFileWizard 0031 */ 0032 void setErrorMessage(const QString &errorMessage); 0033 0034 private: 0035 SendFileWizard *const m_wizard; 0036 std::optional<QString> m_errorMessage; 0037 }; 0038 0039 #endif // FAILPAGE_H