2022-05-15 02:06:02 +02:00
|
|
|
// SPDX-FileCopyrightText: 2017 Citra Emulator Project
|
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
2018-09-16 20:05:51 +02:00
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include <memory>
|
2018-10-26 16:21:45 +02:00
|
|
|
#include <QFutureWatcher>
|
2018-09-16 20:05:51 +02:00
|
|
|
#include <QWizard>
|
2021-09-02 21:40:55 -04:00
|
|
|
#include "core/telemetry_session.h"
|
2018-09-16 20:05:51 +02:00
|
|
|
|
|
|
|
|
namespace Ui {
|
|
|
|
|
class CompatDB;
|
|
|
|
|
}
|
|
|
|
|
|
2022-10-26 15:03:55 +02:00
|
|
|
enum class CompatibilityStatus {
|
|
|
|
|
Perfect = 0,
|
|
|
|
|
Playable = 1,
|
|
|
|
|
// Unused: Okay = 2,
|
|
|
|
|
Ingame = 3,
|
|
|
|
|
IntroMenu = 4,
|
|
|
|
|
WontBoot = 5,
|
|
|
|
|
};
|
|
|
|
|
|
2018-09-16 20:05:51 +02:00
|
|
|
class CompatDB : public QWizard {
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
2021-09-02 21:40:55 -04:00
|
|
|
explicit CompatDB(Core::TelemetrySession& telemetry_session_, QWidget* parent = nullptr);
|
2018-09-16 20:05:51 +02:00
|
|
|
~CompatDB();
|
2022-10-26 15:03:55 +02:00
|
|
|
int nextId() const override;
|
2018-09-16 20:05:51 +02:00
|
|
|
|
|
|
|
|
private:
|
2018-10-26 16:21:45 +02:00
|
|
|
QFutureWatcher<bool> testcase_watcher;
|
|
|
|
|
|
2018-09-16 20:05:51 +02:00
|
|
|
std::unique_ptr<Ui::CompatDB> ui;
|
|
|
|
|
|
|
|
|
|
void Submit();
|
2022-10-26 15:03:55 +02:00
|
|
|
CompatibilityStatus CalculateCompatibility() const;
|
2018-10-26 16:21:45 +02:00
|
|
|
void OnTestcaseSubmitted();
|
2018-09-16 20:05:51 +02:00
|
|
|
void EnableNext();
|
2021-09-02 21:40:55 -04:00
|
|
|
|
|
|
|
|
Core::TelemetrySession& telemetry_session;
|
2018-09-16 20:05:51 +02:00
|
|
|
};
|