v1.2.0: adjusted default fullscreen for desktop, and platform checking

This commit is contained in:
Evan Debenham 2022-02-16 16:27:54 -05:00
parent 776661e739
commit 0c5a0332e5
2 changed files with 5 additions and 4 deletions

View File

@ -24,6 +24,7 @@ package com.watabou.utils;
import com.badlogic.gdx.Application;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.Input;
import com.badlogic.gdx.utils.SharedLibraryLoader;
import com.watabou.noosa.Game;
//TODO migrate to platformSupport class
@ -44,15 +45,15 @@ public class DeviceCompat {
}
public static boolean isAndroid(){
return Gdx.app.getType() == Application.ApplicationType.Android;
return SharedLibraryLoader.isAndroid;
}
public static boolean isiOS(){
return Gdx.app.getType() == Application.ApplicationType.iOS;
return SharedLibraryLoader.isIos;
}
public static boolean isDesktop(){
return Gdx.app.getType() == Application.ApplicationType.Desktop;
return SharedLibraryLoader.isWindows || SharedLibraryLoader.isMac || SharedLibraryLoader.isLinux;
}
public static boolean hasHardKeyboard(){

View File

@ -64,7 +64,7 @@ public class SPDSettings extends GameSettings {
}
public static boolean fullscreen() {
return getBoolean( KEY_FULLSCREEN, false );
return getBoolean( KEY_FULLSCREEN, DeviceCompat.isDesktop() );
}
public static void landscape( boolean value ){