mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-07 14:45:41 +12:00
Merge branch 'master' into fastmem
This commit is contained in:
commit
7dd82a3c9a
1 changed files with 16 additions and 6 deletions
|
@ -135,7 +135,8 @@ ConfigWindow::ConfigWindow(ConfigCallback configCallback, MainWindowCallback win
|
||||||
defaultRomPath->setText(newPath);
|
defaultRomPath->setText(newPath);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
QHBoxLayout* romLayout = new QHBoxLayout;
|
|
||||||
|
QHBoxLayout* romLayout = new QHBoxLayout();
|
||||||
romLayout->setSpacing(4);
|
romLayout->setSpacing(4);
|
||||||
romLayout->addWidget(defaultRomPath);
|
romLayout->addWidget(defaultRomPath);
|
||||||
romLayout->addWidget(browseRomPath);
|
romLayout->addWidget(browseRomPath);
|
||||||
|
@ -250,14 +251,23 @@ ConfigWindow::ConfigWindow(ConfigCallback configCallback, MainWindowCallback win
|
||||||
});
|
});
|
||||||
audioLayout->addRow(tr("Volume curve"), volumeCurveType);
|
audioLayout->addRow(tr("Volume curve"), volumeCurveType);
|
||||||
|
|
||||||
QSpinBox* volumeRaw = new QSpinBox();
|
QLabel* volumeLabel = new QLabel(QString::number(int(config.audioDeviceConfig.volumeRaw * 100)));
|
||||||
volumeRaw->setRange(0, 200);
|
|
||||||
volumeRaw->setValue(config.audioDeviceConfig.volumeRaw * 100);
|
QSlider* volumeSlider = new QSlider(Qt::Horizontal);
|
||||||
connect(volumeRaw, &QSpinBox::valueChanged, this, [&](int value) {
|
volumeSlider->setRange(0, 200);
|
||||||
|
volumeSlider->setValue(int(config.audioDeviceConfig.volumeRaw * 100));
|
||||||
|
connect(volumeSlider, &QSlider::valueChanged, this, [this, volumeLabel](int value) {
|
||||||
config.audioDeviceConfig.volumeRaw = static_cast<float>(value) / 100.0f;
|
config.audioDeviceConfig.volumeRaw = static_cast<float>(value) / 100.0f;
|
||||||
|
volumeLabel->setText(QString::number(value));
|
||||||
|
|
||||||
updateConfig();
|
updateConfig();
|
||||||
});
|
});
|
||||||
audioLayout->addRow(tr("Audio device volume"), volumeRaw);
|
|
||||||
|
QHBoxLayout* volumeLayout = new QHBoxLayout();
|
||||||
|
volumeLayout->setSpacing(4);
|
||||||
|
volumeLayout->addWidget(volumeSlider);
|
||||||
|
volumeLayout->addWidget(volumeLabel);
|
||||||
|
audioLayout->addRow(tr("Audio device volume"), volumeLayout);
|
||||||
|
|
||||||
// Battery settings
|
// Battery settings
|
||||||
QGroupBox* batGroupBox = new QGroupBox(tr("Battery Settings"), this);
|
QGroupBox* batGroupBox = new QGroupBox(tr("Battery Settings"), this);
|
||||||
|
|
Loading…
Add table
Reference in a new issue