Commit Graph

28 Commits

Author SHA1 Message Date
James Rowe
f4bd1fce6f Input: Copy current SDL.h/cpp files to impl
This should make reviewing much easier as you can then see what changed
happened between the old file and the new one
2019-03-02 18:38:11 +01:00
Lioncash
5a5287d917 common/math_util: Move contents into the Common namespace
These types are within the common library, so they should be within the
Common namespace.
2019-02-27 03:38:39 -05:00
Lioncash
7ff6e73155 common/vector_math: Move Vec[x] types into the Common namespace
These types are within the common library, so they should be using the
Common namespace.
2019-02-26 22:38:36 -05:00
Lioncash
898d317430 common/quaternion: Move Quaternion into the Common namespace
Quaternion is within the common library, so it should be using the
Common namespace.
2019-02-26 22:31:17 -05:00
Tobias
86b3a18a93 Port #4141 from citra: Joystick hotplug support (#1275)
* Joystick hotplug support (#4141)

* use SDL_PollEvent instead of SDL_JoystickUpdate

Register hot plugged controller by GUID if they were configured in a previous session

* Move SDL_PollEvent into its own thread

* Don't store SDLJoystick pointer in Input Device; Get pointer on each GetStatus call

* Fix that joystick_list gets cleared after SDL_Quit

* Add VirtualJoystick for InputDevices thats never nullptr

* fixup! Add VirtualJoystick for InputDevices thats never nullptr

* fixup! fixup! Add VirtualJoystick for InputDevices thats never nullptr

* Remove SDL_GameController, make SDL_Joystick* unique_ptr

* fixup! Remove SDL_GameController, make SDL_Joystick* unique_ptr

* Adressed feedback; fixed handling of same guid reconnects

* fixup! Adressed feedback; fixed handling of same guid reconnects

* merge the two joystick_lists into one

* make SDLJoystick a member of VirtualJoystick

* fixup! make SDLJoystick a member of VirtualJoystick

* fixup! make SDLJoystick a member of VirtualJoystick

* fixup! fixup! make SDLJoystick a member of VirtualJoystick

* SDLJoystick: Addressed review comments

* Address one missed review comment
2018-09-10 21:29:59 -04:00
Lioncash
436a2c57ea input_common: Use std::move where applicable
Avoids unnecessary atomic reference count increments and decrements
2018-08-02 21:51:11 -04:00
Lioncash
02b5592618 input_common: Add missing override specifiers 2018-08-02 21:44:25 -04:00
James Rowe
847a518200 Rename logging macro back to LOG_* 2018-07-02 21:45:47 -04:00
Lioncash
f7e5368f1d input_common: Move old logging macros over to fmt-capable ones 2018-04-26 19:09:25 -04:00
Lioncash
ae5156dc73 math_util: Remove the Clamp() function
C++17 adds clamp() to the standard library, so we can remove ours in
favor of it.
2018-04-20 10:14:13 -04:00
James Rowe
7d396de27a Format: Run the new clang format on everything 2018-01-20 16:45:11 -07:00
bunnei
fdfefda960 Merge pull request #84 from lioncash/cmake
CMakeLists: Derive the source directory grouping from targets themselves
2018-01-18 01:37:17 -05:00
Lioncash
6091001deb CMakeLists: Derive the source directory grouping from targets themselves
Removes the need to store to separate SRC and HEADER variables, and then
construct the target in most cases.
2018-01-17 21:51:43 -05:00
Lioncash
90b17d2f16 input_common/sdl: Silence a -Wpessimizing-move warning 2018-01-17 18:44:16 -05:00
muemart
2b8800dd00 Adding meumart's Citra SDL Joystick support. Citra PR #3116 2018-01-15 20:02:30 -05:00
wwylele
c05a90135d motion_emu: fix initialization order 2017-08-22 11:43:44 +03:00
James Rowe
78d01dd905 Merge pull request #2861 from wwylele/motion-refactor
Refactor MotionEmu into a InputDevice
2017-08-19 23:43:01 -06:00
wwylele
c7570dc130 motion_emu: no need to include thread in header 2017-08-19 07:21:02 +03:00
Dave Leaver
d062d550cb Fix Spelling/English mistakes 2017-08-14 09:15:39 +12:00
wwylele
88451a0b73 move MotionEmu from core/frontend to input_common as a InputDevice 2017-08-11 11:05:08 +03:00
danzel
d56b74ac58 Fix some spelling mistakes 2017-08-11 19:51:16 +12:00
Yuri Kunde Schlesner
bd753b8131 CMake: Define an interface target for SDL2 definitions 2017-05-27 21:38:49 -07:00
Yuri Kunde Schlesner
4a5d297fe7 CMake: Correct inter-module dependencies and library visibility
Modules didn't correctly define their dependencies before, which relied
on the frontends implicitly including every module for linking to
succeed.

Also changed every target_link_libraries call to specify visibility of
dependencies to avoid leaking definitions to dependents when not
necessary.
2017-05-27 18:41:24 -07:00
wwylele
2bb38b3a76 input_common/sdl: add support for binding button to axis 2017-04-17 14:14:35 +03:00
wwylele
c22571a470 citra-qt: release all buttons when render window focus is lost
credit to @Hawkheart for the original idea
2017-03-17 21:41:25 +02:00
wwylele
e61d586a0d InputCommon: add SDL joystick support 2017-03-01 23:30:57 +02:00
wwylele
b0898ce5f5 InputCommon: add AnalogFromButton 2017-03-01 23:30:57 +02:00
wwylele
1e713bccda InputCommon: add Keyboard 2017-03-01 23:30:57 +02:00