v3.3.0: fixed deprecated platform checking logic
This commit is contained in:
@@ -23,6 +23,7 @@ package com.watabou.utils;
|
||||
|
||||
import com.badlogic.gdx.Gdx;
|
||||
import com.badlogic.gdx.Input;
|
||||
import com.badlogic.gdx.utils.Os;
|
||||
import com.badlogic.gdx.utils.SharedLibraryLoader;
|
||||
import com.watabou.noosa.Game;
|
||||
|
||||
@@ -35,15 +36,15 @@ public class DeviceCompat {
|
||||
}
|
||||
|
||||
public static boolean isAndroid(){
|
||||
return SharedLibraryLoader.isAndroid;
|
||||
return SharedLibraryLoader.os == Os.Android;
|
||||
}
|
||||
|
||||
public static boolean isiOS(){
|
||||
return SharedLibraryLoader.isIos;
|
||||
return SharedLibraryLoader.os == Os.IOS;
|
||||
}
|
||||
|
||||
public static boolean isDesktop(){
|
||||
return SharedLibraryLoader.isWindows || SharedLibraryLoader.isMac || SharedLibraryLoader.isLinux;
|
||||
return SharedLibraryLoader.os == Os.Windows || SharedLibraryLoader.os == Os.MacOsX || SharedLibraryLoader.os == Os.Linux;
|
||||
}
|
||||
|
||||
public static boolean hasHardKeyboard(){
|
||||
|
||||
Reference in New Issue
Block a user