summaryrefslogtreecommitdiff
path: root/src/input_common/drivers/sdl_driver.h
diff options
context:
space:
mode:
authorGravatar Lioncash2021-12-13 09:05:23 -0500
committerGravatar Lioncash2021-12-13 09:05:50 -0500
commit2b92d22bda767c7c723935c357bea474f8e2d2f8 (patch)
treee732bb3b2062562c031ea54937514ca34ab6e6b1 /src/input_common/drivers/sdl_driver.h
parentinput_engine: Remove callback clearing in constructor (diff)
downloadyuzu-2b92d22bda767c7c723935c357bea474f8e2d2f8.tar.gz
yuzu-2b92d22bda767c7c723935c357bea474f8e2d2f8.tar.xz
yuzu-2b92d22bda767c7c723935c357bea474f8e2d2f8.zip
input_engine: std::move engine name where applicable
We can allow the name to be moved into, allowing allocations to be avoided.
Diffstat (limited to 'src/input_common/drivers/sdl_driver.h')
-rw-r--r--src/input_common/drivers/sdl_driver.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/input_common/drivers/sdl_driver.h b/src/input_common/drivers/sdl_driver.h
index d03ff4b84..c6fffe374 100644
--- a/src/input_common/drivers/sdl_driver.h
+++ b/src/input_common/drivers/sdl_driver.h
@@ -19,19 +19,19 @@ using SDL_GameController = struct _SDL_GameController;
19using SDL_Joystick = struct _SDL_Joystick; 19using SDL_Joystick = struct _SDL_Joystick;
20using SDL_JoystickID = s32; 20using SDL_JoystickID = s32;
21 21
22namespace InputCommon {
23
24class SDLJoystick;
25
22using ButtonBindings = 26using ButtonBindings =
23 std::array<std::pair<Settings::NativeButton::Values, SDL_GameControllerButton>, 17>; 27 std::array<std::pair<Settings::NativeButton::Values, SDL_GameControllerButton>, 17>;
24using ZButtonBindings = 28using ZButtonBindings =
25 std::array<std::pair<Settings::NativeButton::Values, SDL_GameControllerAxis>, 2>; 29 std::array<std::pair<Settings::NativeButton::Values, SDL_GameControllerAxis>, 2>;
26 30
27namespace InputCommon { 31class SDLDriver : public InputEngine {
28
29class SDLJoystick;
30
31class SDLDriver : public InputCommon::InputEngine {
32public: 32public:
33 /// Initializes and registers SDL device factories 33 /// Initializes and registers SDL device factories
34 SDLDriver(const std::string& input_engine_); 34 explicit SDLDriver(std::string input_engine_);
35 35
36 /// Unregisters SDL device factories and shut them down. 36 /// Unregisters SDL device factories and shut them down.
37 ~SDLDriver() override; 37 ~SDLDriver() override;