yuzu: Add volume up/down hotkeys
This commit is contained in:
parent
419f427a01
commit
c8b3a12856
3 changed files with 16 additions and 4 deletions
|
@ -1014,8 +1014,18 @@ void GMainWindow::InitializeHotkeys() {
|
|||
Settings::values.use_docked_mode.GetValue(), *system);
|
||||
dock_status_button->setChecked(Settings::values.use_docked_mode.GetValue());
|
||||
});
|
||||
connect_shortcut(QStringLiteral("Mute Audio"),
|
||||
connect_shortcut(QStringLiteral("Audio Mute/Unmute"),
|
||||
[] { Settings::values.audio_muted = !Settings::values.audio_muted; });
|
||||
connect_shortcut(QStringLiteral("Audio Volume Down"), [] {
|
||||
const auto current_volume = static_cast<int>(Settings::values.volume.GetValue());
|
||||
const auto new_volume = std::max(current_volume - 5, 0);
|
||||
Settings::values.volume.SetValue(static_cast<u8>(new_volume));
|
||||
});
|
||||
connect_shortcut(QStringLiteral("Audio Volume Up"), [] {
|
||||
const auto current_volume = static_cast<int>(Settings::values.volume.GetValue());
|
||||
const auto new_volume = std::min(current_volume + 5, 100);
|
||||
Settings::values.volume.SetValue(static_cast<u8>(new_volume));
|
||||
});
|
||||
connect_shortcut(QStringLiteral("Toggle Framerate Limit"), [] {
|
||||
Settings::values.disable_fps_limit.SetValue(!Settings::values.disable_fps_limit.GetValue());
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue