2023-06-19 22:42:27 +01:00
|
|
|
// SPDX-License-Identifier: GPL-3.0-only
|
|
|
|
/*
|
|
|
|
* Prism Launcher - Minecraft Launcher
|
2023-06-19 23:36:18 +01:00
|
|
|
* Copyright (C) 2023 TheKodeToad <TheKodeToad@proton.me>
|
2023-06-19 22:42:27 +01:00
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, version 3.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <QDialog>
|
|
|
|
#include "ui/pages/BasePageProvider.h"
|
|
|
|
|
|
|
|
class MinecraftInstance;
|
|
|
|
class PageContainer;
|
|
|
|
class PackProfile;
|
2023-06-22 18:18:33 +01:00
|
|
|
class QDialogButtonBox;
|
2023-06-19 22:42:27 +01:00
|
|
|
|
2023-08-02 20:24:15 +01:00
|
|
|
class InstallLoaderDialog final : public QDialog, protected BasePageProvider {
|
2023-06-19 22:42:27 +01:00
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2023-07-01 17:02:39 +01:00
|
|
|
explicit InstallLoaderDialog(std::shared_ptr<PackProfile> instance, const QString& uid = QString(), QWidget* parent = nullptr);
|
2023-06-19 22:42:27 +01:00
|
|
|
|
|
|
|
QList<BasePage*> getPages() override;
|
|
|
|
QString dialogTitle() override;
|
|
|
|
|
2023-07-03 17:32:59 +01:00
|
|
|
void validate(BasePage* page);
|
2023-06-19 22:42:27 +01:00
|
|
|
void done(int result) override;
|
|
|
|
|
|
|
|
private:
|
2023-07-03 17:32:59 +01:00
|
|
|
std::shared_ptr<PackProfile> profile;
|
|
|
|
PageContainer* container;
|
|
|
|
QDialogButtonBox* buttons;
|
2023-06-19 22:42:27 +01:00
|
|
|
};
|