From 65f1aff453227269ca14ea89d8d747e22ff21a35 Mon Sep 17 00:00:00 2001 From: Arisotura Date: Thu, 15 Sep 2022 23:49:10 +0200 Subject: [PATCH] more UI work: make it explicit that some things are instance-unique --- src/frontend/qt_sdl/AudioSettingsDialog.cpp | 10 ++ src/frontend/qt_sdl/AudioSettingsDialog.ui | 11 +- .../qt_sdl/FirmwareSettingsDialog.cpp | 2 +- .../qt_sdl/InputConfig/InputConfigDialog.cpp | 7 + .../qt_sdl/InputConfig/InputConfigDialog.ui | 145 +++++++++--------- 5 files changed, 103 insertions(+), 72 deletions(-) diff --git a/src/frontend/qt_sdl/AudioSettingsDialog.cpp b/src/frontend/qt_sdl/AudioSettingsDialog.cpp index a9b3ade7..dc07d3d2 100644 --- a/src/frontend/qt_sdl/AudioSettingsDialog.cpp +++ b/src/frontend/qt_sdl/AudioSettingsDialog.cpp @@ -67,6 +67,16 @@ AudioSettingsDialog::AudioSettingsDialog(QWidget* parent) : QDialog(parent), ui( bool iswav = (Config::MicInputType == 3); ui->txtMicWavPath->setEnabled(iswav); ui->btnMicWavBrowse->setEnabled(iswav); + + int inst = Platform::InstanceID(); + if (inst > 0) + { + ui->lblInstanceNum->setText(QString("Configuring settings for instance %1").arg(inst+1)); + ui->cbInterpolation->setEnabled(false); + ui->cbBitrate->setEnabled(false); + } + else + ui->lblInstanceNum->hide(); } AudioSettingsDialog::~AudioSettingsDialog() diff --git a/src/frontend/qt_sdl/AudioSettingsDialog.ui b/src/frontend/qt_sdl/AudioSettingsDialog.ui index d7cfadd6..8fc38d92 100644 --- a/src/frontend/qt_sdl/AudioSettingsDialog.ui +++ b/src/frontend/qt_sdl/AudioSettingsDialog.ui @@ -7,7 +7,7 @@ 0 0 482 - 256 + 301 @@ -23,6 +23,13 @@ QLayout::SetFixedSize + + + + Configuring settings for instance X + + + @@ -76,7 +83,7 @@ - <html><head/><body><p>The bitrate of audio playback. If set to "Automatic" this will be 10-bit for DS mode and 16-bit for DSi mode.</p></body></html> + <html><head/><body><p>The bitrate of audio playback. If set to "Automatic" this will be 10-bit for DS mode and 16-bit for DSi mode.</p></body></html> diff --git a/src/frontend/qt_sdl/FirmwareSettingsDialog.cpp b/src/frontend/qt_sdl/FirmwareSettingsDialog.cpp index 7643c1e4..ffca5676 100644 --- a/src/frontend/qt_sdl/FirmwareSettingsDialog.cpp +++ b/src/frontend/qt_sdl/FirmwareSettingsDialog.cpp @@ -18,8 +18,8 @@ #include -#include "Config.h" #include "Platform.h" +#include "Config.h" #include "FirmwareSettingsDialog.h" #include "ui_FirmwareSettingsDialog.h" diff --git a/src/frontend/qt_sdl/InputConfig/InputConfigDialog.cpp b/src/frontend/qt_sdl/InputConfig/InputConfigDialog.cpp index 697e983a..92a01867 100644 --- a/src/frontend/qt_sdl/InputConfig/InputConfigDialog.cpp +++ b/src/frontend/qt_sdl/InputConfig/InputConfigDialog.cpp @@ -24,6 +24,7 @@ #include #include "types.h" +#include "Platform.h" #include "Config.h" #include "MapButton.h" @@ -123,6 +124,12 @@ InputConfigDialog::InputConfigDialog(QWidget* parent) : QDialog(parent), ui(new } setupKeypadPage(); + + int inst = Platform::InstanceID(); + if (inst > 0) + ui->lblInstanceNum->setText(QString("Configuring mappings for instance %1").arg(inst+1)); + else + ui->lblInstanceNum->hide(); } InputConfigDialog::~InputConfigDialog() diff --git a/src/frontend/qt_sdl/InputConfig/InputConfigDialog.ui b/src/frontend/qt_sdl/InputConfig/InputConfigDialog.ui index 15cb683d..0db61b15 100644 --- a/src/frontend/qt_sdl/InputConfig/InputConfigDialog.ui +++ b/src/frontend/qt_sdl/InputConfig/InputConfigDialog.ui @@ -7,7 +7,7 @@ 0 0 770 - 719 + 678 @@ -20,7 +20,7 @@ QLayout::SetFixedSize - + Qt::Horizontal @@ -30,49 +30,7 @@ - - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - 0 - 0 - - - - Joystick: - - - - - - - - 0 - 0 - - - - <html><head/><body><p>Selects which joystick will be used for joystick input, if any is present.</p></body></html> - - - - - - + 0 @@ -167,7 +125,7 @@ - 76 + 70 0 @@ -258,7 +216,7 @@ - 76 + 70 0 @@ -384,7 +342,7 @@ - 76 + 70 0 @@ -464,7 +422,7 @@ - 76 + 70 0 @@ -523,7 +481,7 @@ - 76 + 70 0 @@ -615,7 +573,7 @@ - 76 + 70 0 @@ -698,7 +656,7 @@ - 76 + 70 0 @@ -757,7 +715,7 @@ - 76 + 70 0 @@ -882,7 +840,7 @@ - 76 + 70 0 @@ -962,7 +920,7 @@ - 76 + 70 0 @@ -1021,7 +979,7 @@ - 76 + 70 0 @@ -1113,7 +1071,7 @@ - 76 + 70 0 @@ -1289,7 +1247,7 @@ - 76 + 70 0 @@ -1441,7 +1399,7 @@ - 76 + 70 0 @@ -1521,7 +1479,7 @@ - 76 + 70 0 @@ -1580,7 +1538,7 @@ - 76 + 70 0 @@ -1672,7 +1630,7 @@ - 76 + 70 0 @@ -1814,7 +1772,7 @@ - 76 + 70 0 @@ -1894,7 +1852,7 @@ - 76 + 70 0 @@ -1953,7 +1911,7 @@ - 76 + 70 0 @@ -2045,7 +2003,7 @@ - 76 + 70 0 @@ -2128,7 +2086,7 @@ - 76 + 70 0 @@ -2187,7 +2145,7 @@ - 76 + 70 0 @@ -2251,7 +2209,7 @@ - 76 + 70 0 @@ -2321,6 +2279,55 @@ + + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + 0 + 0 + + + + Joystick: + + + + + + + + 0 + 0 + + + + <html><head/><body><p>Selects which joystick will be used for joystick input, if any is present.</p></body></html> + + + + + + + + + Configuring mappings for instance X + + +