1 /*  RetroArch - A frontend for libretro.
2  *  Copyright (C) 2010-2014 - Hans-Kristian Arntzen
3  *  Copyright (C) 2011-2017 - Daniel De Matteis
4  *
5  *  RetroArch is free software: you can redistribute it and/or modify it under the terms
6  *  of the GNU General Public License as published by the Free Software Found-
7  *  ation, either version 3 of the License, or (at your option) any later version.
8  *
9  *  RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
10  *  without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  *  PURPOSE.  See the GNU General Public License for more details.
12  *
13  *  You should have received a copy of the GNU General Public License along with RetroArch.
14  *  If not, see <http://www.gnu.org/licenses/>.
15  */
16 
17 #include <stdint.h>
18 #include <stdlib.h>
19 
20 #ifdef HAVE_CONFIG_H
21 #include "../../config.h"
22 #endif
23 
24 #ifdef _XBOX
25 #include <xtl.h>
26 #endif
27 
28 #include <boolean.h>
29 #include <libretro.h>
30 
31 #include "../../config.def.h"
32 
33 #include "../input_driver.h"
34 
xdk_input_free_input(void * data)35 static void xdk_input_free_input(void *data) { }
xdk_input_init(const char * a)36 static void *xdk_input_init(const char *a) { return (void*)-1; }
37 
xdk_input_get_capabilities(void * data)38 static uint64_t xdk_input_get_capabilities(void *data)
39 {
40    return (1 << RETRO_DEVICE_JOYPAD) | (1 << RETRO_DEVICE_ANALOG);
41 }
42 
43 input_driver_t input_xinput = {
44    xdk_input_init,
45    NULL,                         /* poll */
46    NULL,                         /* input_state */
47    xdk_input_free_input,
48    NULL,
49    NULL,
50    xdk_input_get_capabilities,
51    "xinput",
52    NULL,                         /* grab_mouse */
53    NULL
54 };
55