From 9dd0f952e09471f15f59a98c1ae650d99499cd77 Mon Sep 17 00:00:00 2001 From: Loïc Blot Date: Tue, 15 Aug 2017 20:30:30 +0200 Subject: Modernize client code (#6250) * Various code style fixes * Use range based for loops * Use empty instead of empty objects * Use C++11 default keyword for trivial constructors and destructors * Drop some useless casts * Use emplace_back instead of push_back to improve performance of some vectors push --- src/client/joystick_controller.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/client/joystick_controller.h') diff --git a/src/client/joystick_controller.h b/src/client/joystick_controller.h index baec4e412..4a2cdf555 100644 --- a/src/client/joystick_controller.h +++ b/src/client/joystick_controller.h @@ -52,7 +52,8 @@ struct JoystickCombination { struct JoystickButtonCmb : public JoystickCombination { - JoystickButtonCmb() {} + JoystickButtonCmb() = default; + JoystickButtonCmb(GameKeyType key, u32 filter_mask, u32 compare_mask) : filter_mask(filter_mask), compare_mask(compare_mask) @@ -68,7 +69,8 @@ struct JoystickButtonCmb : public JoystickCombination { struct JoystickAxisCmb : public JoystickCombination { - JoystickAxisCmb() {} + JoystickAxisCmb() = default; + JoystickAxisCmb(GameKeyType key, u16 axis_to_compare, int direction, s16 thresh) : axis_to_compare(axis_to_compare), direction(direction), -- cgit v1.2.3