From 2aaf18b0b81717c06d9591fddcc6fd9ec6fcbce2 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Thu, 10 Oct 2019 22:28:37 -0400 Subject: [PATCH] v0.7.5b: SPD-classes and core are no longer android-specific modules! --- SPD-classes/build.gradle | 16 +++------------- SPD-classes/src/main/AndroidManifest.xml | 8 -------- .../java/com/watabou/utils/DeviceCompat.java | 4 ++-- android/src/main/AndroidManifest.xml | 5 +++-- core/build.gradle | 12 ++---------- core/src/main/AndroidManifest.xml | 7 ------- 6 files changed, 10 insertions(+), 42 deletions(-) delete mode 100644 SPD-classes/src/main/AndroidManifest.xml delete mode 100644 core/src/main/AndroidManifest.xml diff --git a/SPD-classes/build.gradle b/SPD-classes/build.gradle index 523ab0edd..7a26783d9 100644 --- a/SPD-classes/build.gradle +++ b/SPD-classes/build.gradle @@ -1,22 +1,12 @@ -//FIXME currently an android library while small amounts of android-specific code remain -apply plugin: 'com.android.library' +apply plugin: 'java-library' -android { - compileSdkVersion appAndroidCompileSDK - - defaultConfig { - //noinspection MinSdkTooLow - minSdkVersion appAndroidMinSDK - } -} - -configurations { natives } +[compileJava, compileTestJava]*.options*.encoding = 'UTF-8' dependencies { //TODO migrate this to implementation from api //in order to do this I have to remove 100% of libGDX API access from core api "com.badlogicgames.gdx:gdx:$gdxVersion" - api "com.badlogicgames.gdx:gdx-backend-android:$gdxVersion" implementation "com.badlogicgames.gdx:gdx-controllers:$gdxVersion" implementation "com.badlogicgames.gdx:gdx-freetype:$gdxVersion" + implementation "org.json:json:20190722" } diff --git a/SPD-classes/src/main/AndroidManifest.xml b/SPD-classes/src/main/AndroidManifest.xml deleted file mode 100644 index 4595a71eb..000000000 --- a/SPD-classes/src/main/AndroidManifest.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - diff --git a/SPD-classes/src/main/java/com/watabou/utils/DeviceCompat.java b/SPD-classes/src/main/java/com/watabou/utils/DeviceCompat.java index db2d56f93..c3b36675a 100644 --- a/SPD-classes/src/main/java/com/watabou/utils/DeviceCompat.java +++ b/SPD-classes/src/main/java/com/watabou/utils/DeviceCompat.java @@ -22,7 +22,7 @@ package com.watabou.utils; import com.badlogic.gdx.Gdx; -import com.watabou.BuildConfig; +import com.watabou.noosa.Game; //TODO migrate to platformSupport class public class DeviceCompat { @@ -50,7 +50,7 @@ public class DeviceCompat { } public static boolean isDebug(){ - return BuildConfig.DEBUG; + return Game.version.contains("INDEV"); } public static void openURI( String URI ){ diff --git a/android/src/main/AndroidManifest.xml b/android/src/main/AndroidManifest.xml index 372edef3f..d4912f29e 100644 --- a/android/src/main/AndroidManifest.xml +++ b/android/src/main/AndroidManifest.xml @@ -3,8 +3,9 @@ package="com.shatteredpixel.shatteredpixeldungeon.android" android:installLocation="auto"> - + + + diff --git a/core/build.gradle b/core/build.gradle index a0c4520b5..720ae960f 100644 --- a/core/build.gradle +++ b/core/build.gradle @@ -1,14 +1,6 @@ -//FIXME currently an android library while small amounts of android-specific code remain in SPD-classes -apply plugin: 'com.android.library' +apply plugin: 'java-library' -android { - compileSdkVersion appAndroidCompileSDK - - defaultConfig { - //noinspection MinSdkTooLow - minSdkVersion appAndroidMinSDK - } -} +[compileJava, compileTestJava]*.options*.encoding = 'UTF-8' dependencies { api project(':SPD-classes') diff --git a/core/src/main/AndroidManifest.xml b/core/src/main/AndroidManifest.xml deleted file mode 100644 index 075b395ca..000000000 --- a/core/src/main/AndroidManifest.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - -