mirror of
https://github.com/PabloMK7/citra.git
synced 2024-11-25 17:04:04 +00:00
enum class
This commit is contained in:
parent
169b076913
commit
fc1bdc3c62
2 changed files with 5 additions and 5 deletions
|
@ -24,6 +24,8 @@ CompatDB::CompatDB(QWidget* parent)
|
|||
|
||||
CompatDB::~CompatDB() = default;
|
||||
|
||||
enum class CompatDBPage { Intro = 0, Selection = 1, Final = 2 };
|
||||
|
||||
void CompatDB::Submit() {
|
||||
QButtonGroup* compatibility = new QButtonGroup(this);
|
||||
compatibility->addButton(ui->radioButton_Perfect, 0);
|
||||
|
@ -32,13 +34,13 @@ void CompatDB::Submit() {
|
|||
compatibility->addButton(ui->radioButton_Bad, 3);
|
||||
compatibility->addButton(ui->radioButton_IntroMenu, 4);
|
||||
compatibility->addButton(ui->radioButton_WontBoot, 5);
|
||||
switch (currentId()) {
|
||||
case CompatDBPage::SelectionPage:
|
||||
switch ((static_cast<CompatDBPage>(currentId()))) {
|
||||
case CompatDBPage::Selection:
|
||||
if (compatibility->checkedId() == -1) {
|
||||
button(NextButton)->setEnabled(false);
|
||||
}
|
||||
break;
|
||||
case CompatDBPage::FinalPage:
|
||||
case CompatDBPage::Final:
|
||||
LOG_DEBUG(Frontend, "Compatibility Rating: %d", compatibility->checkedId());
|
||||
Core::Telemetry().AddField(Telemetry::FieldType::UserFeedback, "Compatibility",
|
||||
compatibility->checkedId());
|
||||
|
|
|
@ -25,5 +25,3 @@ private slots:
|
|||
void Submit();
|
||||
void EnableNext();
|
||||
};
|
||||
|
||||
enum CompatDBPage { IntroPage = 0, SelectionPage = 1, FinalPage = 2 };
|
||||
|
|
Loading…
Reference in a new issue