v0.8.0: added an update notification service
This commit is contained in:
+6
@@ -29,6 +29,8 @@ import com.badlogic.gdx.backends.lwjgl3.Lwjgl3Preferences;
|
||||
import com.badlogic.gdx.utils.SharedLibraryLoader;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.SPDSettings;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ShatteredPixelDungeon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.services.updates.UpdateImpl;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.services.updates.Updates;
|
||||
import com.watabou.noosa.Game;
|
||||
import com.watabou.utils.FileUtils;
|
||||
import com.watabou.utils.Point;
|
||||
@@ -79,6 +81,10 @@ public class DesktopLauncher {
|
||||
} catch (NumberFormatException e) {
|
||||
Game.versionCode = Integer.parseInt(System.getProperty("Implementation-Version"));
|
||||
}
|
||||
|
||||
if (UpdateImpl.supportsUpdates()){
|
||||
Updates.service = UpdateImpl.getUpdateService();
|
||||
}
|
||||
|
||||
Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
|
||||
|
||||
|
||||
+5
@@ -58,6 +58,11 @@ public class DesktopPlatformSupport extends PlatformSupport {
|
||||
} );
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean connectedToUnmeteredNetwork() {
|
||||
return true; //no easy way to check this in desktop, just assume user doesn't care
|
||||
}
|
||||
|
||||
@Override
|
||||
public void promptTextInput(String title, String hintText, int maxLen, boolean multiLine, String posTxt, String negTxt, TextCallback callback) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user