CommonHostInterface: Add proper fast forward toggle
This commit is contained in:
parent
194fc63232
commit
a111e36ad7
|
@ -401,7 +401,6 @@ void CommonHostInterface::SetDefaultSettings(SettingsInterface& si)
|
|||
si.SetStringValue("Hotkeys", "IncreaseResolutionScale", "Keyboard/PageUp");
|
||||
si.SetStringValue("Hotkeys", "DecreaseResolutionScale", "Keyboard/PageDown");
|
||||
si.SetStringValue("Hotkeys", "ToggleSoftwareRendering", "Keyboard/End");
|
||||
|
||||
}
|
||||
|
||||
std::optional<CommonHostInterface::HostKeyCode>
|
||||
|
@ -720,12 +719,23 @@ bool CommonHostInterface::AddRumbleToInputMap(const std::string& binding, u32 co
|
|||
|
||||
void CommonHostInterface::RegisterGeneralHotkeys()
|
||||
{
|
||||
RegisterHotkey(StaticString("General"), StaticString("FastForward"), StaticString("Toggle Fast Forward"),
|
||||
RegisterHotkey(StaticString("General"), StaticString("FastForward"), StaticString("Fast Forward"),
|
||||
[this](bool pressed) {
|
||||
m_speed_limiter_temp_disabled = pressed;
|
||||
HostInterface::UpdateSpeedLimiterState();
|
||||
});
|
||||
|
||||
RegisterHotkey(StaticString("General"), StaticString("ToggleFastForward"), StaticString("Toggle Fast Forward"),
|
||||
[this](bool pressed) {
|
||||
if (!pressed)
|
||||
{
|
||||
m_speed_limiter_temp_disabled = !m_speed_limiter_temp_disabled;
|
||||
HostInterface::UpdateSpeedLimiterState();
|
||||
AddFormattedOSDMessage(1.0f, "Speed limiter %s.",
|
||||
m_speed_limiter_enabled ? "enabled" : "disabled");
|
||||
}
|
||||
});
|
||||
|
||||
RegisterHotkey(StaticString("General"), StaticString("ToggleFullscreen"), StaticString("Toggle Fullscreen"),
|
||||
[this](bool pressed) {
|
||||
if (!pressed)
|
||||
|
|
Loading…
Reference in New Issue