Commit graph

84 commits

Author SHA1 Message Date
Nekotekina 8e6e57de86 Enable -Wunused-function warning 2021-02-15 14:39:53 +03:00
Megamouse bc938ce630 dualsense: implement player LEDs 2021-02-09 19:21:37 +01:00
Megamouse db402cb8af dualsense: add player LED support 2021-02-09 19:21:37 +01:00
Megamouse 1af6550db7 dualsense: add lightbar support 2021-02-09 19:21:37 +01:00
Megamouse 7795f5207f dualsense: fix switched motors
The left one seems to be the large motor
2021-02-09 19:21:37 +01:00
Megamouse a9b8a50c31 dualsense: add output report structs based on linux driver 2021-02-09 19:21:37 +01:00
Megamouse a9418fa1e7 dualsense: implement SetPadData for rumble in GUI 2021-02-09 19:21:37 +01:00
Megamouse 08f48d27e8 Input: minor simplification
This might prevent some copy paste error in the future
2021-02-09 19:21:37 +01:00
Megamouse 25a66da4ca Input: rename some functions 2021-02-09 19:21:37 +01:00
Megamouse ff61bc9e7c dualsense: add mic button 2021-02-09 19:21:37 +01:00
Megamouse 3e8f4ba018 dualsense: add gyro support 2021-02-09 19:21:37 +01:00
Megamouse 7e0fdbbe99 Fix rpcs3.vcxproj 2021-02-04 23:11:05 +01:00
Nekotekina a6a92f7b6b Qt: remove Q_OBJECT for mouse/kb handlers
Had to move QObject in parent list for g_fxo changes.
2021-02-04 23:11:05 +01:00
Megamouse 51d19e7c31 Input: remove debug error 2021-01-28 18:02:23 +01:00
Megamouse 8eaf76394c Qt/Input: Use ellipsis as "mouse deadzone"
This is experimental and smoothens the existing square shaped deadzone
2021-01-13 11:25:33 +01:00
Nekotekina db8e6fe7a7 Enable -Wunused-variable 2021-01-12 14:34:14 +03:00
Megamouse 52deff06ba
Random stuff (#9589)
* minor coding style adjustment

* Qt: simplify osk dialog buttons

* replace std::find_if with convenience functions

* RSX: use sv in swizzle comparison

idk, I'll remove this if it was intentional.

* overlays/osk: rename enter to return

This one confused me and make me look for a bug that caused the "enter" key to be disabled, while it was actually the return key (obviously xD).
2021-01-12 12:59:50 +03:00
Nekotekina a8e0d261b7 types.hpp: more cleanup
Also fix compilation.
2020-12-22 19:08:09 +03:00
Nekotekina 43a58df8a0 Butcher narrow cast a little (don't print value).
Also remove some forward declarations from util/types.hpp
If they don't work properly, it's easier to remove them.
2020-12-22 14:32:30 +03:00
Nekotekina b7bf316c1a Don't randomly include "stdafx.h"
It's file for precompiled headers.
Include what is used, don't rely on transitive includes.
2020-12-22 14:32:30 +03:00
Nekotekina fb29933d3d Add usz alias for std::size_t 2020-12-18 12:23:53 +03:00
Megamouse 03ad5c6830
Salvaging code (#9432)
* Minor input refactoring

* fix sys_config_unregister_io_error_listener log message

* Remove unused variables in RepaintTextColors

Co-authored-by: GermanAizek <GermanAizek@yandex.ru>
2020-12-14 14:33:43 +01:00
Megamouse 35ecd00559 Remove BOM from new files 2020-12-14 09:01:07 +03:00
Luke Barr cb8ef46ec7
Initial DualSense Support (#9308)
* Initial DualSense Support

* Add Vibration Support

* Add CRC32 Validation to Incoming Bluetooth Packets
Cleanup report sizes

* Consistency, remove button comments, add two buttons.

Co-authored-by: Ani <ani-leo@outlook.com>
2020-12-13 00:00:45 +01:00
Nekotekina 6e05dcadb6 Reduce std::numeric_limits dependency
Please, stop pretending...
You need these templates for generic code.
In other words, in another templates.
Stop increasing compilation time for no reason.
2020-12-12 12:35:18 +03:00
Nekotekina aa3aef4beb std::chrono cleanup: always use steady_clock 2020-12-11 19:01:56 +03:00
Nekotekina e055d16b2c Replace verify() with ensure() with auto src location.
Expression ensure(x) returns x.
Using comma operator removed.
2020-12-09 15:43:38 +03:00
RipleyTom af8c661a64 Remove BOM markers 2020-12-06 15:30:12 +03:00
Megamouse 9e352da052 Handle some undefined behavior regarding null pads 2020-11-26 00:45:49 +01:00
Megamouse 4984e87776 implement interception for cellKb and cellMouse
this needs to be tested
2020-10-31 02:11:27 +03:00
Megamouse 0a121e9d26 DS4: Add error logging and remove some unused code 2020-10-27 15:25:08 +01:00
Bevan Weiss 04deb97f94 MSVC 16.8 Preview 3.1 compiler fix
The latest MSVC 16.8 Preview 3.1 cl.exe no longer likes the implicit conversion from false->std::shared_ptr
But it's happy with nullptr

Not the ideal solution, but it will kick the can down the road a little.
2020-09-23 12:44:32 +02:00
Megamouse 5d50602397 Qt/Input: fix default pad handler
We accidentally always saved keyboard to Player 1 if null was selected.
The new code will only apply keyboard by default if the config file was not found.
2020-09-22 06:59:38 +02:00
SEt 9a6aac1662
Improve pad support (#8800)
* Add support for another DS3 HID Report ID for Win7
* Add support for reading accel/gyro pad data over SCP
2020-09-16 22:36:06 +02:00
Megamouse f0053bfc1a Input/Qt: Dont lock unused mouse in keyboard pad 2020-09-09 00:22:48 +02:00
Megamouse 1dac01498c Update mouse lock logic
- fix headers
- update cursor whenever the mouse is moved
- unify cursor logic
- move m_mouse_hide_and_lock logic to handle_cursor (toggle_fullscreen is the trigger, not the handler)
- disable mouse lock and idle timer if the window is inactive
2020-09-02 14:22:00 +02:00
Bevan Weiss ae0e454fc2 Use dynamic_cast to convert QWindow m_target to gs_frame
Used to access get_mouse_lock_state rather than going through the QWindow property tables.

Modify mouse hide and lock to default OFF when entering Windowed mode, and to default ON when entering Fullscreen unless 'show cursor in fullscreen' is configured
2020-09-02 14:22:00 +02:00
Bevan Weiss ca3ee019cc GUI: Mouse Hide and Lock Keyboard Shortcut
This should address the second point of #4502.

A few notes:
1. it changes the current behaviour of the 'Fullscreen cursor'.  Currently it defaults to be captive.  This changes it so that it defaults to NOT being captive, but can be made captive with the CTRL+L key combination.
2. There are situations when in windowed mode it's possible to escape the captivity (it's like a minigame if you will).  This requires the mouse movement to exceed the bounds of the window in a single event scan.  It will just show up as a temporary visibility of the cursor when outside of the window bounds.  It's not too difficult to 'fix', but might not be a likely enough scenario to warrant either.
3. There currently isn't an ability to change what this keyboard combo maps to, but it's inline with a collection of other similar keyboard mappings.  I think adding such a more generic keyboard mapping system (not for just keypad items, but system items.. e.g. so that Emulator stop could be mapped to something other than CTRL+S etc) is a bit out-of-scope of this particular PR.
2020-09-02 14:22:00 +02:00
Megamouse 9af66e22da evdev: log axis information in pad settings 2020-08-18 18:29:35 +02:00
Megamouse 4d9533ea54 input: use left and right squircle values 2020-07-13 21:23:48 +02:00
Megamouse f1b1c9053c Input/Qt: Check if gui callbacks are nullptr 2020-07-04 14:28:19 +02:00
Megamouse b5f01372ee Windows: distinguish left and right modifiers
This is just some workaround until we either use a different input api for keyboards or until we refactor the keyboard_pad_handler to use Qt with native scan codes
2020-07-02 12:55:27 +02:00
Megamouse bec6bde919 Qt/Input: update keyboard_pad_handler shortcuts
This is just some patchwork before the shortcuts get refactored eventually
2020-07-02 12:55:27 +02:00
Megamouse 1f25924384 Qt/Input: remove unused function: GetModifierCode 2020-07-02 12:55:27 +02:00
Megamouse 5a8eb9d3d7 Input: skip keyboard input when pads are disabled 2020-06-26 09:28:58 +02:00
Megamouse ab4c40c988 pad_thread facepalm 2020-06-26 09:28:58 +02:00
Megamouse 76faaf43f7 Input: Use global variables for pad modifications 2020-06-26 04:42:52 +02:00
Megamouse eb5ec211c2 Input: remember registered ldd controllers
- Don't reset ldd pads when saving a pad config
- Prevent configuration of registered ldd pads in the gui while ingame
2020-05-13 11:17:58 +02:00
Megamouse 5c4b8e8dee Input: fix xinput deadzones 2020-05-06 09:33:38 +02:00
Megamouse d4606cfdb9 Input: remame some functions 2020-05-06 09:33:38 +02:00