Fraser Waters
e855d2eb33
[Input] Legacy keyboard respects the KeyRepeat field.
...
If the legacy keyboard device receives a key down event with IsRepeat set it
will only raise it's own key down event if it's KeyRepeat field is set to true.
This is as documented, regression casused by refactoring. Fixes issue #201 .
Also change the GameWindowState example to show setting of KeyRepeat to true
and false and how that changes the event counts for the legacy and new keyboard
devices.
2014-11-23 14:40:36 +01:00
xThaWolfx
077bf0d65e
Update MouseEventArgs.cs
...
The IsPressed field was never updated as the pressed parameter was never used.
2014-10-13 17:58:47 +02:00
thefiddler
3bf29b074c
[Input] Fixed debug display of Back gamepad button
2014-09-18 01:20:21 +02:00
thefiddler
10dd7e8227
[Input] Special-case pre-SDL2.0.4 xinput bindings
...
Starting with SDL 2.0.4, its xinput bindings are working correctly.
Previous versions would return an invalid zero guid and use incorrect
mapping - this has now been fixed.
2014-09-17 23:48:08 +02:00
thefiddler
71e5a4f4f3
[Input] Add GamePadCapabilities.IsMapped
2014-09-12 08:42:26 +02:00
thefiddler
0735700d50
[Input] Added P880 win32 gamepad configuration
2014-09-11 12:51:50 +02:00
thefiddler
bf9f7c9479
[Input] Fixed trigger ToString()
2014-09-11 12:51:50 +02:00
thefiddler
6c2a6336b5
[Input] Added missing Back button in ToString()
2014-09-11 12:51:50 +02:00
thefiddler
ec37a9a16d
[Input] Do not throw exception on too many axes
...
A joystick device with more axes/buttons/hats than supported will now
register a warning message instead of throwing an exception.
Fixes an issue with the VMware touch driver, which registers 25 distinct
axes.
2014-09-11 12:51:49 +02:00
thefiddler
f81046f27d
[Win] Corrected GUID for xinput devices
2014-09-11 12:51:49 +02:00
thefiddler
15a79e5213
[Input] Improved GamePadButtons.ToString()
2014-09-11 12:51:48 +02:00
thefiddler
cbb2807959
[Win] Implemented joystick button updates
...
Due to the way we segregate axes from buttons, the easiest approach is
to retrieve the current button state via HidP_GetUsages().
Axes, buttons and hats are now allocated sequentially based on their
order of appearance in the device capability reports.
2014-09-11 12:51:48 +02:00
thefiddler
131de67459
Fixed minor compilation issues
2014-09-11 12:51:47 +02:00
Stefanos A
e38fc0dff7
[Input] Added JoystickCapabilities.SetIsConnected
2014-09-11 12:51:47 +02:00
Stefanos A
14d07a5952
[Win] Corrected XInput Guid in gamepad database
...
All XInput devices expose the same button layout, so they only need a
single entry in the gamepad configuration database.
2014-09-11 12:51:45 +02:00
thefiddler
c6989395df
[Input] Added GameWindow.Mouse/Keyboard.GetState()
...
GameWindow.Mouse/Keyboard hide OpenTK.Input.Mouse/Keyboard.
To simplify usage, the former now provide the same methods
as the latter.
2014-09-11 01:03:24 +02:00
thefiddler
e5cd6a3b9e
[Input] Implemented JoystickHat GamePad mapping
2014-07-25 23:26:03 +02:00
thefiddler
7c55e4e9ec
[Input] Corrected invalid GUID in GamePad database
2014-07-24 01:10:22 +02:00
thefiddler
3e9b2005d1
[Input] Sync GamePad database with SDL 2.0.4
2014-07-24 00:19:41 +02:00
thefiddler
00b531fdef
Fixed compilation warnings on Mono 3.4.0
2014-07-21 17:46:39 +02:00
thefiddler
461fbce45f
Cleaned up a number of obsolete warnings
2014-07-21 16:39:58 +02:00
thefiddler
ead151ea4f
Fixed a large number of warnings
2014-07-21 16:03:37 +02:00
thefiddler
340d34b07b
[Input] MouseState position is now stored in floating point
...
Several platforms provide subpixel accuracy for mouse position.
OpenTK can now take advantage of that.
2014-07-16 14:28:27 +02:00
thefiddler
3febb4dda0
[Input] Renamed MouseScrollWheel to MouseScroll
...
This better describes the functionality of this structure.
2014-05-13 23:25:56 +02:00
thefiddler
c6dafbccba
[X11] Implemented high-resolution scroll events
2014-05-13 23:23:51 +02:00
thefiddler
bb8dfe4304
[Input] Improve SDL2 and Windows GetCursorState
2014-05-12 02:20:52 +02:00
thefiddler
f4a3cab0e0
[Input] Added Mouse.GetCursorPos() (WIP)
2014-05-12 02:20:52 +02:00
thefiddler
c98b4ea178
[Input] Do not hook FocusedChanged
...
This is handled by NativeWindowBase now.
2014-05-09 15:23:39 +02:00
thefiddler
8b7d5bc7e4
[Input] Implement key repeat
2014-05-05 00:43:45 +02:00
thefiddler
d968281a1b
[OpenTK] Refactor keyboard and mouse handling
...
A lot of duplicated code is now moved to NativeWindowBase and
LegacyInputDriver.
2014-05-04 17:05:08 +02:00
thefiddler
268e8fccde
[Input] Removed pointless unsafe region
2014-05-04 17:01:34 +02:00
thefiddler
1096a8802a
[Input] Removed pointless ValuePrecise setter
2014-05-04 16:58:59 +02:00
thefiddler
7af710f4dd
[Input] Removed pointless MouseDevice.SetState
...
MouseDevice state should only be modified through its HandleMouse*
methods, not directly.
2014-05-04 16:58:24 +02:00
thefiddler
67359a5d90
[Input] MouseDevice is now based on MouseState
...
This way we have a single state representation (MouseState), shared by
all mouse APIs and events.
2014-05-04 08:33:20 +02:00
thefiddler
39eb3b1892
[Input] Improved MouseState.ToString()
2014-05-04 08:31:11 +02:00
thefiddler
94fdf1881c
[Platform] Improved mouse interface
...
- The complete mouse state is now available in mouse events
- Horizontal wheels are now supported
- MouseState now takes up less memory and has a simpler internal
implementation.
2014-05-04 01:29:55 +02:00
thefiddler
e85377c350
[Platform] Added support for horizontal wheel
2014-05-03 16:47:03 +02:00
thefiddler
3e33ac9280
[Platform] Refactored INativeWindow backends
...
All INativeWindow implementations are now derived from
NativeWindowBase. They no longer implement legacy IInputDriver
themselves, but rather rely on LegacyInputDriver provided by
NativeWindowBase for compatibility. They also implement the new Mouse*
events.
2014-05-02 16:52:11 +02:00
thefiddler
612652910f
[Platform] Inherit NativeWindowBase
2014-05-02 14:18:40 +02:00
thefiddler
24b19d2487
[Input] Added internal MouseDevice.Position getter
2014-05-02 09:37:25 +02:00
thefiddler
d03e9d82dc
[Input] Fixed key modifiers in KeyboardDevice events
2014-04-27 22:27:18 +02:00
thefiddler
3658fac263
[Input] Use Key.LastKey instead of Enum.GetValues
...
This avoids unnecessary memory allocations in the KeyboardDevice
constructor.
2014-04-25 14:15:06 +02:00
thefiddler
f93d464f62
[Input] JoystickHatState is now IEquatable
2014-03-17 00:30:04 +01:00
thefiddler
01c3b51be6
[Input] JoystickState.ToString now prints hat pos
2014-03-17 00:29:45 +01:00
thefiddler
c92aabd807
[Input] Implemented GetModifiers() method
2014-02-25 01:13:45 +01:00
thefiddler
221d4661d4
[Input] Added modifier keys to KeyboardKeyEventArgs
2014-02-25 01:13:45 +01:00
thefiddler
4066ba8355
[Input] Added KeyModifiers enumeration
...
KeyModifiers are represented as a bitwise combination of the Alt,
Control and Shift keys.
2014-02-25 01:13:45 +01:00
thefiddler
ae3f8cff55
[Doc] Fixed doxygen latex-to-pdf conversion
...
pdflatex will fail when a <seealso> elements is placed within a
<summary> element. This is now fixed.
2014-02-16 15:30:22 +01:00
Stefanos A.
2dee96d918
[Input] Fixed SetButton index check
2014-01-31 16:40:57 +01:00
Stefanos A.
4fceca2f80
[Input] Fixed compilation error
2014-01-31 16:37:36 +01:00