aboutsummaryrefslogtreecommitdiffstats
path: root/libgamepad.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2022-07-26 16:10:41 +0200
committerMattias Andrée <maandree@kth.se>2022-07-26 16:14:00 +0200
commit08184b90b04961086e7b00650651188a9652a0c5 (patch)
tree204dd698fd9efb83955ad58506018591cc56ca59 /libgamepad.h
parentDo not relay on libevdev for button/axis names, an prepare for device specific names, and add reverse lookup functions (diff)
downloadlibgamepad-08184b90b04961086e7b00650651188a9652a0c5.tar.gz
libgamepad-08184b90b04961086e7b00650651188a9652a0c5.tar.bz2
libgamepad-08184b90b04961086e7b00650651188a9652a0c5.tar.xz
Hide implementation details
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--libgamepad.h23
1 files changed, 7 insertions, 16 deletions
diff --git a/libgamepad.h b/libgamepad.h
index d039082..404e526 100644
--- a/libgamepad.h
+++ b/libgamepad.h
@@ -20,6 +20,11 @@
*/
typedef struct libgamepad_attachment_monitor LIBGAMEPAD_ATTACHMENT_MONITOR;
+/**
+ * Opaque structure for internal data in `struct libgamepad_device`
+ */
+typedef struct libgamepad_device_internals LIBGAMEPAD_DEVICE_INTERNALS;
+
/**
* Device attachment event type
@@ -1259,18 +1264,9 @@ struct libgamepad_device {
unsigned int version;
/**
- * FOR INTERNAL USE
- *
- * Specifies whether `.fd` shall be closed with the device
+ * Data for internal use
*/
- int close_fd;
-
- /**
- * FOR INTERNAL USE
- *
- * Whether the device must be synchronised
- */
- int require_sync;
+ LIBGAMEPAD_DEVICE_INTERNALS *internals;
/**
* Human-readable device (sub- or superdevice) name
@@ -1289,11 +1285,6 @@ struct libgamepad_device {
const char *physical_location;
/**
- * libevdev instance for the device
- */
- struct libevdev *dev;
-
- /**
* Number of (digital) buttons/keys present
* on the device
*/