diff options
| author | 2021-03-27 19:07:59 -0500 | |
|---|---|---|
| committer | 2021-03-30 21:40:36 -0500 | |
| commit | d9db1d125eedc57654310131f8f8bf6d3431fabf (patch) | |
| tree | 2949c8f15ce02acfdadbfdd73ac5469315859ae1 /src/input_common/sdl/sdl_impl.h | |
| parent | Merge pull request #6114 from Morph1984/friend-log (diff) | |
| download | yuzu-d9db1d125eedc57654310131f8f8bf6d3431fabf.tar.gz yuzu-d9db1d125eedc57654310131f8f8bf6d3431fabf.tar.xz yuzu-d9db1d125eedc57654310131f8f8bf6d3431fabf.zip | |
InputCommon: Name properly xbox 360 and one controllers, Fix mappings for Nintendo Pro controllers
Diffstat (limited to '')
| -rw-r--r-- | src/input_common/sdl/sdl_impl.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/input_common/sdl/sdl_impl.h b/src/input_common/sdl/sdl_impl.h index 08044b00d..8b7363f56 100644 --- a/src/input_common/sdl/sdl_impl.h +++ b/src/input_common/sdl/sdl_impl.h | |||
| @@ -14,6 +14,7 @@ | |||
| 14 | #include "input_common/sdl/sdl.h" | 14 | #include "input_common/sdl/sdl.h" |
| 15 | 15 | ||
| 16 | union SDL_Event; | 16 | union SDL_Event; |
| 17 | using SDL_GameController = struct _SDL_GameController; | ||
| 17 | using SDL_Joystick = struct _SDL_Joystick; | 18 | using SDL_Joystick = struct _SDL_Joystick; |
| 18 | using SDL_JoystickID = s32; | 19 | using SDL_JoystickID = s32; |
| 19 | 20 | ||
| @@ -64,6 +65,9 @@ private: | |||
| 64 | /// Needs to be called before SDL_QuitSubSystem. | 65 | /// Needs to be called before SDL_QuitSubSystem. |
| 65 | void CloseJoysticks(); | 66 | void CloseJoysticks(); |
| 66 | 67 | ||
| 68 | /// Returns a custom name for specific controllers because the default name is not correct | ||
| 69 | std::string GetControllerName(SDL_GameController* controller) const; | ||
| 70 | |||
| 67 | // Set to true if SDL supports game controller subsystem | 71 | // Set to true if SDL supports game controller subsystem |
| 68 | bool has_gamecontroller = false; | 72 | bool has_gamecontroller = false; |
| 69 | 73 | ||