Report 0 joysticks to SDL if neither accelerometer nor on-screen keyboard is used
This commit is contained in:
@@ -456,7 +456,7 @@ class Settings
|
|||||||
nativeSetTrackballUsed();
|
nativeSetTrackballUsed();
|
||||||
if( Globals.AppUsesMouse )
|
if( Globals.AppUsesMouse )
|
||||||
nativeSetMouseUsed();
|
nativeSetMouseUsed();
|
||||||
if( Globals.AppUsesJoystick )
|
if( Globals.AppUsesJoystick && (Globals.UseAccelerometerAsArrowKeys || Globals.UseTouchscreenKeyboard) )
|
||||||
nativeSetJoystickUsed();
|
nativeSetJoystickUsed();
|
||||||
if( Globals.AppUsesMultitouch )
|
if( Globals.AppUsesMultitouch )
|
||||||
nativeSetMultitouchUsed();
|
nativeSetMultitouchUsed();
|
||||||
|
|||||||
@@ -661,7 +661,12 @@ void SDL_ANDROID_processAndroidTrackballDampening()
|
|||||||
|
|
||||||
int SDL_SYS_JoystickInit(void)
|
int SDL_SYS_JoystickInit(void)
|
||||||
{
|
{
|
||||||
SDL_numjoysticks = MAX_MULTITOUCH_POINTERS+1;
|
SDL_numjoysticks = 0;
|
||||||
|
if( SDL_ANDROID_isJoystickUsed )
|
||||||
|
SDL_numjoysticks = 1;
|
||||||
|
if( isMultitouchUsed )
|
||||||
|
SDL_numjoysticks = MAX_MULTITOUCH_POINTERS+1;
|
||||||
|
|
||||||
return(SDL_numjoysticks);
|
return(SDL_numjoysticks);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user