mirror of https://github.com/xemu-project/xemu.git
Input/Config: Setting to disable controller vibration/rumble
This commit is contained in:
parent
c720af00bb
commit
58ee60037e
|
@ -54,6 +54,9 @@ input:
|
||||||
auto_bind:
|
auto_bind:
|
||||||
type: bool
|
type: bool
|
||||||
default: true
|
default: true
|
||||||
|
allow_vibration:
|
||||||
|
type: bool
|
||||||
|
default: true
|
||||||
background_input_capture: bool
|
background_input_capture: bool
|
||||||
keyboard_controller_scancode_map:
|
keyboard_controller_scancode_map:
|
||||||
# Scancode reference : https://github.com/libsdl-org/SDL/blob/main/include/SDL_scancode.h
|
# Scancode reference : https://github.com/libsdl-org/SDL/blob/main/include/SDL_scancode.h
|
||||||
|
|
|
@ -490,7 +490,7 @@ void xemu_input_update_sdl_controller_state(ControllerState *state)
|
||||||
|
|
||||||
void xemu_input_update_rumble(ControllerState *state)
|
void xemu_input_update_rumble(ControllerState *state)
|
||||||
{
|
{
|
||||||
if (!state->rumble_enabled) {
|
if (!state->rumble_enabled || !g_config.input.allow_vibration) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -485,6 +485,8 @@ void MainMenuInputView::Draw()
|
||||||
SectionTitle("Options");
|
SectionTitle("Options");
|
||||||
Toggle("Auto-bind controllers", &g_config.input.auto_bind,
|
Toggle("Auto-bind controllers", &g_config.input.auto_bind,
|
||||||
"Bind newly connected controllers to any open port");
|
"Bind newly connected controllers to any open port");
|
||||||
|
Toggle("Controller vibration", &g_config.input.allow_vibration,
|
||||||
|
"Allows the controllers to vibrate");
|
||||||
Toggle("Background controller input capture",
|
Toggle("Background controller input capture",
|
||||||
&g_config.input.background_input_capture,
|
&g_config.input.background_input_capture,
|
||||||
"Capture even if window is unfocused (requires restart)");
|
"Capture even if window is unfocused (requires restart)");
|
||||||
|
|
Loading…
Reference in New Issue