citra-qt: Add an "Alternative Speed Limit" with its hotkey (#5281)
* Change "Toggle Speed Limit" to toggle between 100% and a custom value This will change the shortcut for "Toggle Speed Limit" to make it swap between 100% and the value of "Limit Speed Percent" in the config. Old functionality is still there, but renamed to "Unthrottle". * Complete reimplementation of the function * Fix something that didn't get saved correctly * Fix missing indentation * Rewrite to keep only a single QSpinBox * Second rewrite * set Unthrottled to 0 in the Qspinbox * Hotkey for Unthrottle * minor improvements to the design * Apply suggestions from code review Co-authored-by: Ben <bene_thomas@web.de> * Default slider values * clang-format fixes * Prevent the speed slider from changing size ...when an element in its row has variable width. * Change "Game Speed" to "Emulation Speed" * Apply suggestions from code review `game_speed` to` emulation_speed` Co-authored-by: Valentin Vanelslande <vvanelslandedev@gmail.com> * Fix for QSliders * Revert "Prevent the speed slider from changing size" This reverts commit ddaca2004484f1e024f49d2e6dc99ef5e261f64d. * clang-format ...doesn't seem to stick to a choice * Fix 2 for QSliders Co-authored-by: B3n30 <benediktthomas@gmail.com> Co-authored-by: Ben <bene_thomas@web.de> Co-authored-by: Valentin Vanelslande <vvanelslandedev@gmail.com>
This commit is contained in:
parent
6d65319c85
commit
485d64ae73
11 changed files with 259 additions and 61 deletions
|
@ -244,6 +244,10 @@ ConfigureSystem::ConfigureSystem(QWidget* parent) : QWidget(parent), ui(new Ui::
|
|||
}
|
||||
}
|
||||
|
||||
// Set a minimum width for the label to prevent the slider from changing size.
|
||||
// This scales across DPIs. (This value should be enough for "xxx%")
|
||||
ui->clock_display_label->setMinimumWidth(40);
|
||||
|
||||
connect(ui->slider_clock_speed, &QSlider::valueChanged, [&](int value) {
|
||||
ui->clock_display_label->setText(QStringLiteral("%1%").arg(SliderToSettings(value)));
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue