Commit Graph

85 Commits

Author SHA1 Message Date
sirmangler
25010e59e0 Merge remote-tracking branch 'upstream/master'
# Conflicts:
#	CMakeLists.txt
#	Externals/Qt~upstream_master
#	Readme.md
#	Source/Core/Core/Config/MainSettings.h
#	Source/Core/DolphinLib.vcxproj
#	Source/Core/DolphinQt/CMakeLists.txt
#	Source/Core/DolphinQt/DolphinQt.vcxproj
#	Source/Core/UICommon/DiscordPresence.cpp
#	Source/Core/WinUpdater/WinUpdater.vcxproj
2022-09-14 19:26:41 +01:00
Admiral H. Curtiss
9d15a1c5a1
Merge pull request #10858 from AdmiralCurtiss/mouse-center-hotkey
Add hotkey for centering mouse in render window.
2022-07-26 12:52:33 +02:00
Shawn Hoffman
f92541fbd9 StripSpaces: only strip spaces
StripWhitespace maintains old behavior
2022-07-25 18:40:12 -07:00
Admiral H. Curtiss
d57d04bb04
DInput: Handle mouse centering hotkey. 2022-07-25 01:26:56 +02:00
Admiral H. Curtiss
89067e66f9
InputCommon: Get rid of static strings. 2022-07-15 19:53:10 +02:00
vyuuui
5f9a37566a Updated to Updated to 5.0-16380 2022-05-26 20:27:42 -07:00
Jordan Woyak
566dfc1cf4 ControllerInterface: Update sort priorities. 2022-04-03 19:03:44 -05:00
SirMangler
afc0fb127d Updated to 5.0-15993 2022-02-25 18:06:17 +00:00
Pokechu22
ca9bf3174f Use HRWrap in remaining locations
Note that D3DCommon can't use DX11HRWrap or DX12HRWrap since it's shared between them.
2022-01-09 12:44:55 -08:00
Pokechu22
2025763420 Treewide: Adjust order of includes 2021-12-10 14:49:57 -08:00
Filoppi
125971d9f2 InputCommon: fix default input config default device not being loaded/found
Fixes bug: https://bugs.dolphin-emu.org/issues/12744

Before e1e3db13ba
the ControllerInterface m_devices_mutex was "wrongfully" locked for the whole Initialize() call, which included the first device population refresh,
this has the unwanted (accidental) consequence of often preventing the different pads (GC Pad, Wii Contollers, ...) input configs from loading
until that mutex was released (the input config defaults loading was blocked in EmulatedController::LoadDefaults()), which meant that the devices
population would often have the time to finish adding its first device, which would then be selected as default device (by design, the first device
added to the CI is the default default device, usually the "Keyboard and Mouse" device).

After the commit mentioned above removed the unnecessary m_devices_mutex calls, the default default device would fail to load (be found)
causing the default input mappings, which are specifically written for the default default device on every platform, to not be bound to any
physical device input, breaking input on new dolphin installations (until a user tried to customize the default device manually).

Default devices are now always added synchronously to avoid the problem, and so they should in the future (I added comments and warnings to help with that)
2021-12-05 23:35:47 +02:00
shiiion
600e1f67ce Merge commit 'db02b50d2ecdfbbc21e19aadc57253c353069f77'
Merged beta 5.0-15445
2021-11-14 20:18:25 -08:00
Pokechu22
78bfd25964 Fix all uninitialized variable warnings (C26495) 2021-10-13 12:32:16 -07:00
SirMangler
4190e5a45c Updated to Beta 5.0-14790 2021-08-15 10:09:23 +01:00
Pierre Bourdon
e149ad4f0a
treewide: convert GPLv2+ license info to SPDX tags
SPDX standardizes how source code conveys its copyright and licensing
information. See https://spdx.github.io/spdx-spec/1-rationale/ . SPDX
tags are adopted in many large projects, including things like the Linux
kernel.
2021-07-05 04:35:56 +02:00
Filoppi
8b53af9cbc ControllerInterface: polish DInput Keyboard and Mouse (add comments and logs)
Also fix the cursor axis not being updated when the mouse device had failed aquiring,
despite them being completely unrelated
2021-06-07 11:07:06 +03:00
Filoppi
038b57fecc ControllerInterface: DInput Joystick fix non thread safe static variable
also fix devices being added to its own custom list of devices even when rejected by the CI
2021-06-07 11:07:06 +03:00
Filoppi
a0ecca1a84 ControllerInterface: Implement ChangeWindow on DInput without recreating the devices
Also polished DInput code in general to try and mitigate issue 11702.
Added a lot of logging and comments.
2021-06-07 11:07:06 +03:00
Filoppi
dcc345400e ControllerInterface: devices population is now async so implement devices sorting priority
This helps us keeping the most important devices (e.g. Mouse and Keyboard) on the top
of the list of devices (they still are on all OSes supported by dolphin
and to make hotplug devices like DSU appear at the bottom.
2021-06-07 11:07:06 +03:00
Filoppi
f90d851e25 ControllerInterface: mixed comments 2021-06-07 11:07:05 +03:00
SirMangler
35cf0def0b Updated to beta 5.0-13963 2021-04-08 21:00:25 +01:00
SirMangler
3e69e1cdaf Merged with beta 5.0-13603 2021-03-28 02:15:27 +01:00
iwubcode
db4b4e40cb InputCommon / DolphinQt / Core: Add a "RelativeMouse" input which provides the raw delta mouse input
Co-authored-by: Jordan Woyak <jordan.woyak@gmail.com>
2021-03-17 20:58:33 -05:00
Shawn Hoffman
7e1df34735 rename InputCommon/ControllerInterface/Device to CoreDevice 2021-01-27 14:29:48 -08:00
Filippo Tarpini
5a5c815ff0
Fix DInput cursor going to +infinite if the window size was 0 2021-01-02 18:33:13 +02:00
SirMangler
870d410b22 Merged with beta 5.0-13178 2020-12-20 22:40:43 +00:00
Lioncash
a5e1415e74 InputCommon: Migrate logging over to fmt
Continues the migration of the logging calls over to the fmt capable
ones.
2020-10-23 13:16:18 -04:00
SirMangler
9f110eeda9 Updated to beta 5.0-12716
3 months of changes, and Qt was being a pain.
2020-10-07 05:00:37 +01:00
Jordan Woyak
f015c99a51 ControllerInterface: Add platform consistent names for modifier keys. 2020-09-25 20:29:18 -05:00
JosJuice
15d9fab0bb Common: Rename UTF16ToUTF8
This function does *not* always convert from UTF-16. It converts
from UTF-16 on Windows and UTF-32 on other operating systems.

Also renaming UTF8ToUTF16 for consistency, even though it
technically doesn't have the same problem since it only was
implemented on Windows.
2020-07-08 14:51:35 +02:00
SirMangler
248899bfc6 Merged to latest Progress Report revision. 2020-04-05 17:30:59 +01:00
Jordan Woyak
da12f3eebc InputCommon: Constify Device::Input::IsDetectable function. 2020-02-22 10:27:43 -06:00
SirMangler
5ecba915c0 Updated to January review. Minor code changes. 2020-02-11 03:01:39 +00:00
Jordan Woyak
4f47cccd9f Cleanup: Use std::abs instead of abs. 2020-02-08 18:21:14 -06:00
Jordan Woyak
b92f6480a0 InputCommon: Make "Cursor" inputs aware of the rendered aspect ratio. 2020-01-24 09:20:41 -06:00
SirMangler
25d10fa59d Removed <windows.h> from DInput and added initialised XInput2 in ControllerInterface, this should fix problems for linux. 2019-10-21 17:42:41 +01:00
SirMangler
6f12108eb2 undid linux "fix" 2019-10-21 16:57:56 +01:00
SirMangler
d6b1399653 Removed a nonexistent class from CMakeLists and patched for Linux 2019-10-21 16:57:13 +01:00
SirMangler
4857c96bb0 Implemented PrimeHack 2019-10-15 20:46:02 +01:00
Lioncash
37d643c7d3 InputCommon/DInputJoystick: Correct force-feedback flag testing
Introduced in a995e2f5ba

We need to be performing a bitwise AND on the flags and not a logical
AND, otherwise we could end up counting device objects that don't
support forced feedback.
2019-08-02 10:26:44 -04:00
Lioncash
ec60027f56 InputCommon: Use nested namespace specifiers where applicable 2019-06-17 16:51:41 -04:00
spycrab
98d808ab71 InputCommon/DInput.h: Add missing include 2019-05-08 21:01:46 +02:00
Techjar
ff972e3673 Reformat repo to clang-format 7.0 rules 2019-05-06 18:48:04 +00:00
Jordan Woyak
8c1310d1d1 ControllerInterface/DInput: Optimize cursor position updating. 2019-04-20 09:25:11 -05:00
Jordan Woyak
eadbdd6bc3 ControllerInterface/Win32: Prevent devcies from losing their "id" on a hotplug event. 2019-03-29 09:04:16 -05:00
Michael M
d26c1ce24d Add hotplug support to DInput and XInput controller backends 2019-03-29 08:01:40 -05:00
Jordan Woyak
b53636827b ControllerInterface: Unbreak DirectInput POV Hats having bad values on init. 2019-03-19 16:05:49 -05:00
Jordan Woyak
48b69ca018 ControllerInterface: Input detection improvements. 2019-03-03 18:36:16 -06:00
Jordan Woyak
a7c45fb49e DirectInput: Use more than 8 bits of precision on axis inputs. 2019-01-06 08:14:37 -06:00
Jordan Woyak
a995e2f5ba ControllerInterface: Set DInput FF effect parameters sanely. This fixes a crash with periodic effects and my GCPad adapter (probably a divide by zero behind the scenes). 2019-01-05 13:00:04 -06:00