mirror of
https://github.com/glfw/glfw.git
synced 2026-09-21 16:44:11 +00:00
Added initial XInput2 cursor motion.
This commit is contained in:
+13
-1
@@ -44,6 +44,9 @@
|
||||
// The XRandR extension provides mode setting and gamma control
|
||||
#include <X11/extensions/Xrandr.h>
|
||||
|
||||
// The XInput2 extension provides improved input events
|
||||
#include <X11/extensions/XInput2.h>
|
||||
|
||||
// The Xkb extension provides improved keyboard support
|
||||
#include <X11/XKBlib.h>
|
||||
|
||||
@@ -94,7 +97,7 @@ typedef struct _GLFWwindowX11
|
||||
GLboolean cursorGrabbed; // True if cursor is currently grabbed
|
||||
GLboolean cursorHidden; // True if cursor is currently hidden
|
||||
GLboolean cursorCentered; // True if cursor was moved since last poll
|
||||
int cursorPosX, cursorPosY;
|
||||
double cursorPosX, cursorPosY;
|
||||
|
||||
} _GLFWwindowX11;
|
||||
|
||||
@@ -153,6 +156,15 @@ typedef struct _GLFWlibraryX11
|
||||
int versionMinor;
|
||||
} xkb;
|
||||
|
||||
struct {
|
||||
GLboolean available;
|
||||
int majorOpcode;
|
||||
int eventBase;
|
||||
int errorBase;
|
||||
int versionMajor;
|
||||
int versionMinor;
|
||||
} xi2;
|
||||
|
||||
// LUT for mapping X11 key codes to GLFW key codes
|
||||
int keyCodeLUT[256];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user