Commit graph

39 commits

Author SHA1 Message Date
Morph
4c621b9b09 Project Mjölnir: Part 2 - Controller Applet
Co-authored-by: Its-Rei <kupfel@gmail.com>
2020-09-04 12:23:25 -04:00
FearlessTobi
01dbe3a624 Address review comments and fix code compilation 2020-08-29 20:56:51 +02:00
FearlessTobi
2903f0f7ce yuzu: Add motion and touch configuration 2020-08-29 18:56:34 +02:00
Lioncash
affbf8e188 input_common: Eliminate most global state
Abstracts most of the input mechanisms under an InputSubsystem class
that is managed by the frontends, eliminating any static constructors
and destructors. This gets rid of global accessor functions and also
allows the frontends to have a more fine-grained control over the
lifecycle of the input subsystem.

This also makes it explicit which interfaces rely on the input subsystem
instead of making it opaque in the interface functions. All that remains
to migrate over is the factories, which can be done in a separate
change.
2020-08-27 16:11:17 -04:00
Morph
24ce544120 Address feedback 2020-08-26 02:32:32 -04:00
Morph
34a209d15c Project Mjölnir: Part 1
Co-authored-by: James Rowe <jroweboy@gmail.com>
Co-authored-by: Its-Rei <kupfel@gmail.com>
2020-08-26 02:32:32 -04:00
Morph
53d2442a44 When docked mode is checked, uncheck "joycons docked" 2019-09-16 23:26:32 -04:00
Silent
70c839c55d Qt: Fixed behaviour of buttons by connecting functors to correct signals
Following screens got fixes:
- Configure/Debug
- Configure/Input
2019-08-02 04:09:38 +02:00
Lioncash
fb580dcda2 yuzu/configuration: Make all widgets and dialogs aware of language changes
To prepare for translation support, this makes all of the widgets
cognizant of the language change event that occurs whenever
installTranslator() is called and automatically retranslates their text
where necessary.

This is important as calling the backing UI's retranslateUi() is often
not enough, particularly in cases where we add our own strings that
aren't controlled by it. In that case we need to manually refresh the
strings ourselves.
2019-06-05 21:57:21 -04:00
Lioncash
5bcab18c77 yuzu/configuration: Make function naming consistent 2019-06-05 15:40:33 -04:00
Lioncash
1bea3a5ca2 yuzu/configuration/configure_input: Mark controller type names as translateable
These are user-facing strings, so they should be localizable.
2019-05-19 11:23:25 -04:00
Zach Hilman
885644cdcf configure_input_simple: Properly signal docked mode change 2018-12-05 14:05:57 -05:00
Zach Hilman
5169c4b326 configure_input: Convert into QDialog 2018-12-05 14:02:02 -05:00
Lioncash
1b3b2e69a0 yuzu/configuration/configure_input: Default destructor in the cpp file
The previous code could potentially be a compilation issue waiting to
occur, given we forward declare the type for a std::unique_ptr. If the
complete definition of the forward declared type isn't visible in a
translation unit that the class is used in, then it would fail to
compile.

Defaulting the destructor in a cpp file ensures the std::unique_ptr's
destructor is only invoked where its complete type is known.
2018-12-02 14:18:26 -05:00
Lioncash
6910b79f18 configure_input: Amend clang-format discrepancies 2018-11-30 03:31:56 -05:00
bunnei
1e3699cf58 Merge pull request #1768 from greggameplayer/patch-2
Uncheck automatically joycons docked when docked mode is enable
2018-11-29 01:00:09 -05:00
Lioncash
fd252d2e82 yuzu/configure_input: Make CallConfigureDialog a non-member template function
This doesn't depend on any part of the private interface, so it can be
made a non-member internal function.
2018-11-27 16:37:18 -05:00
Lioncash
7e4436fe22 yuzu/configure_input: Remove unnecessary includes 2018-11-27 05:00:56 -05:00
greggameplayer
103c4be2a3 correct clang-format 2018-11-22 18:26:43 +01:00
greggameplayer
797d3473b4 Automatically disable joycons docked
when docked mode is enable
2018-11-22 01:24:39 +01:00
Zach Hilman
63d941fb6a configure_input: Properly update UI components on removal of player 2018-11-18 23:22:36 -05:00
Zach Hilman
b131a4bbb2 configure_input: Make None a controller option instead of checkbox 2018-11-18 23:22:36 -05:00
Zach Hilman
2d8a5a4e9b hid: Use player-defined controller type as PREFERRED_CONTROLLER 2018-11-18 23:22:36 -05:00
Zach Hilman
b43b2d857f configure_input: Add support for multiplayer and controller types
This moves the actual button configuration to a separate dialog and only has the enabled and type controls in the tab.
2018-11-18 23:22:36 -05:00
Frederic L
c76f4b6aec global: Use std::optional instead of boost::optional (#1578)
* get rid of boost::optional

* Remove optional references

* Use std::reference_wrapper for optional references

* Fix clang format

* Fix clang format part 2

* Adressed feedback

* Fix clang format and MacOS build
2018-10-30 00:03:25 -04:00
zhupengfei
18b712829f citra_qt/configuration: misc input tab improvements
* Added a context menu on the buttons including Clear & Restore Default

* Allow clearing (unsetting) inputs. Added a Clear All button

* Allow restoring a single input to default (instead of all)
2018-10-06 15:43:49 +02:00
Lioncash
6ef4721dd0 configure_input: Make analog mapping strings translatable
These strings are user-facing, so they should be specified as
translatable with tr().
2018-10-02 20:28:45 -04:00
Tobias
ab39d25ff0 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
fearlessTobi
6d2e4b74c2 Port #3911 from Citra: "Optimize settings application" 2018-07-29 14:37:18 +02:00
James Rowe
ea88c44eb8 Format: Run the new clang format on everything 2018-01-20 16:45:11 -07:00
bunnei
2af2310e1b Merge pull request #53 from nkatz565/nk-fixlabels
Implement Pull #3240 from Citra: Add button labels for sdl joystick mappings
2018-01-16 17:55:59 -05:00
muemart
48bb562f1d Use static functions instead of lambdas 2018-01-16 16:49:48 -05:00
muemart
40dc44228e Add translation support for button labels 2018-01-16 16:49:41 -05:00
muemart
4b0302de21 Add button labels for sdl joystick mappings 2018-01-16 16:49:29 -05:00
MerryMage
41bfd994f6 clang-format 2018-01-16 18:05:21 +00:00
muemart
a884f3d03e Adding meumart's Citra SDL Joystick support. Citra PR #3116 2018-01-15 20:02:30 -05:00
shinyquagsire23
974f097bbd configure_input: update w/ Switch buttons 2018-01-15 02:30:53 -07:00
James Rowe
bd5740a721 Remove gpu debugger and get yuzu qt to compile 2018-01-12 19:11:04 -07:00
James Rowe
5dbd091a80 Massive removal of unused modules 2018-01-12 19:11:03 -07:00
Renamed from src/citra_qt/configuration/configure_input.cpp (Browse further)