src/joystick/SDL_gamecontroller.c
changeset 6738 b408d5a406a3
parent 6708 1fa41febb331
child 6823 e9d312d26979
--- a/src/joystick/SDL_gamecontroller.c	Tue Dec 11 10:50:45 2012 -0800
+++ b/src/joystick/SDL_gamecontroller.c	Tue Dec 11 11:54:32 2012 -0800
@@ -48,7 +48,7 @@
 /* our in memory mapping db between joystick objects and controller mappings*/
 struct _SDL_ControllerMapping
 {
-	JoystickGUID guid;
+	SDL_JoystickGUID guid;
 	const char *name;
 
 	// mapping of axis/button id to controller version
@@ -71,7 +71,7 @@
 /* our hard coded list of mapping support */
 typedef struct _ControllerMapping_t
 {
-	JoystickGUID guid;
+	SDL_JoystickGUID guid;
 	char *name;
 	const char *mapping;
 	struct _ControllerMapping_t *next;
@@ -458,7 +458,7 @@
 /*
  * Make a new button mapping struct
  */
-void SDL_PrivateLoadButtonMapping( struct _SDL_ControllerMapping *pMapping, JoystickGUID guid, const char *pchName, const char *pchMapping )
+void SDL_PrivateLoadButtonMapping( struct _SDL_ControllerMapping *pMapping, SDL_JoystickGUID guid, const char *pchName, const char *pchMapping )
 {
 	int j;
 
@@ -673,7 +673,7 @@
 	}
 	else
 	{
-		JoystickGUID jGUID = SDL_JoystickGetDeviceGUID( device_index );
+		SDL_JoystickGUID jGUID = SDL_JoystickGetDeviceGUID( device_index );
 		pSupportedController = s_pSupportedControllers;
 		while ( pSupportedController )
 		{
@@ -700,10 +700,11 @@
 	}
 	else
 	{
-		JoystickGUID jGUID = SDL_JoystickGetDeviceGUID( device_index );
+		SDL_JoystickGUID jGUID = SDL_JoystickGetDeviceGUID( device_index );
 		pSupportedController = s_pSupportedControllers;
 		// debug code to help get the guid string for a new joystick
-		/*const char *pchGUID = SDL_JoystickGetGUIDString( jGUID );
+		/* char szGUID[33];
+		SDL_JoystickGetGUIDString( jGUID, szGUID, sizeof(szGUID) );
 		printf( "%s\n", pchGUID );
 		SDL_free( pchGUID );*/
 		while ( pSupportedController )
@@ -759,7 +760,7 @@
 	pSupportedController =  SDL_PrivateGetControllerMapping(device_index);
 	if ( !pSupportedController )
 	{
-		JoystickGUID jGUID;
+		SDL_JoystickGUID jGUID;
 
 		jGUID = SDL_JoystickGetDeviceGUID( device_index );
 		pSupportedController = s_pSupportedControllers;