Fix the IOS Accelerometer which wasn't fully linked to lime
The SDL implementation of IOS Accelerometer was correct. Wrapped around the Joystick API for commodity I guess, but working. The problem was in fact that LIME didn't linked the joystick itself... After few long hours, the obvious was found, the define was wrong. IPHONE instead of IOS did fix the problem.
This commit is contained in:
@@ -55,7 +55,7 @@ namespace lime {
|
|||||||
|
|
||||||
void SDLJoystick::Init () {
|
void SDLJoystick::Init () {
|
||||||
|
|
||||||
#if defined(IOS) || defined(ANDROID) || defined(TVOS)
|
#if defined(IPHONE) || defined(ANDROID) || defined(TVOS)
|
||||||
for (int i = 0; i < SDL_NumJoysticks (); i++) {
|
for (int i = 0; i < SDL_NumJoysticks (); i++) {
|
||||||
|
|
||||||
if (strstr (SDL_JoystickNameForIndex (i), "Accelerometer")) {
|
if (strstr (SDL_JoystickNameForIndex (i), "Accelerometer")) {
|
||||||
@@ -122,4 +122,4 @@ namespace lime {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user