From 53aa251008e4a484e3acd8dc658c617dff52e115 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Tue, 17 Nov 2015 06:54:59 +0100 Subject: [PATCH] (joypad_connection.h) Cleanups --- input/connect/joypad_connection.h | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/input/connect/joypad_connection.h b/input/connect/joypad_connection.h index c9f1842b0e..34898b06be 100644 --- a/input/connect/joypad_connection.h +++ b/input/connect/joypad_connection.h @@ -23,6 +23,13 @@ typedef void (*send_control_t)(void *data, uint8_t *buf, size_t size); +struct joypad_connection +{ + bool connected; + struct pad_connection_interface *iface; + void* data; +}; + typedef struct pad_connection_interface { void* (*init)(void *data, uint32_t slot, send_control_t ptr); @@ -34,17 +41,12 @@ typedef struct pad_connection_interface int16_t (*get_axis)(void *data, unsigned axis); } pad_connection_interface_t; +typedef struct joypad_connection joypad_connection_t; + extern pad_connection_interface_t pad_connection_wii; extern pad_connection_interface_t pad_connection_ps3; extern pad_connection_interface_t pad_connection_ps4; -typedef struct joypad_connection -{ - bool connected; - struct pad_connection_interface *iface; - void* data; -} joypad_connection_t; - int32_t pad_connection_pad_init(joypad_connection_t *joyconn, const char* name, uint16_t vid, uint16_t pid, void *data, send_control_t ptr);