Kaynağa Gözat

Android is now using API level 19 (Android 4.4).

Joachim Meyer 9 yıl önce
ebeveyn
işleme
8c788ccf99

+ 1 - 1
build/android/Polycode2DPhysics/build.gradle

@@ -8,7 +8,7 @@ android {
 
     defaultConfig {
     applicationId "org.polycode.polycode2dphysics"
-        minSdkVersion 14
+        minSdkVersion 19
         targetSdkVersion 23
         versionCode 1
         versionName "1.0"

+ 1 - 1
build/android/Polycode2DPhysics/jni/Application.mk

@@ -1,4 +1,4 @@
-APP_PLATFORM := android-21
+APP_PLATFORM := android-19
 APP_ABI := armeabi x86
 APP_STL := gnustl_static
 APP_CPPFLAGS += -std=c++11

+ 1 - 1
build/android/Polycode3DPhysics/build.gradle

@@ -8,7 +8,7 @@ android {
 
     defaultConfig {
     applicationId "org.polycode.polycode3dphysics"
-        minSdkVersion 14
+        minSdkVersion 19
         targetSdkVersion 23
         versionCode 1
         versionName "1.0"

+ 1 - 1
build/android/Polycode3DPhysics/jni/Application.mk

@@ -1,4 +1,4 @@
-APP_PLATFORM := android-21
+APP_PLATFORM := android-19
 APP_ABI := armeabi x86
 APP_STL := gnustl_static
 APP_CPPFLAGS += -std=c++11

+ 1 - 1
build/android/PolycodeUI/build.gradle

@@ -8,7 +8,7 @@ android {
 
     defaultConfig {
     applicationId "org.polycode.polycodeui"
-        minSdkVersion 14
+        minSdkVersion 19
         targetSdkVersion 23
         versionCode 1
         versionName "1.0"

+ 1 - 1
build/android/PolycodeUI/jni/Application.mk

@@ -1,4 +1,4 @@
-APP_PLATFORM := android-21
+APP_PLATFORM := android-19
 APP_ABI := armeabi x86
 APP_STL := gnustl_static
 APP_CPPFLAGS += -std=c++11

+ 1 - 1
build/android/Polycore/build.gradle

@@ -6,7 +6,7 @@ android {
     buildToolsVersion "23.0.2"
     defaultConfig {
         applicationId "org.polycode.polycore"
-        minSdkVersion 14
+        minSdkVersion 19
         targetSdkVersion 23
         versionCode 1
         versionName "1.0"

+ 1 - 1
build/android/Polycore/jni/Application.mk

@@ -1,4 +1,4 @@
-APP_PLATFORM := android-21
+APP_PLATFORM := android-19
 APP_ABI := armeabi x86
 APP_STL := gnustl_static
 APP_CPPFLAGS += -std=c++11

+ 1 - 1
build/android/TemplateApp/build.gradle

@@ -7,7 +7,7 @@ android {
     buildToolsVersion '23.0.2'
     defaultConfig {
         applicationId "org.polycode.templateapp"
-        minSdkVersion 14
+        minSdkVersion 19
         targetSdkVersion 23
         versionCode 1
         versionName "1.0"

+ 1 - 1
build/android/TemplateApp/jni/Application.mk

@@ -1,4 +1,4 @@
-APP_PLATFORM := android-21
+APP_PLATFORM := android-19
 APP_ABI := armeabi x86
 APP_STL := gnustl_static
 APP_CPPFLAGS += -std=c++11

+ 2 - 0
include/polycode/view/android/PolycodeView.h

@@ -44,6 +44,8 @@
 #define LOGI(text) ((void)__android_log_write(ANDROID_LOG_INFO, "TemplateApp", text))
 #define LOGE(text) ((void)__android_log_write(ANDROID_LOG_ERROR, "TemplateApp", text))
 
+#define ACONFIGURATION_DENSITY_XXXHIGH 640
+
 namespace Polycode {
 	
 	enum{

+ 1 - 1
src/core/PolyAAssetFileProvider.cpp

@@ -107,7 +107,7 @@ long AAssetFile::write( const void * ptr, size_t size, size_t count) {
 }
 
 int AAssetFile::seek(long int offset, int origin) {
-	return AAsset_seek(file, offset, origin);
+	return AAsset_seek64(file, offset, origin);
 }
 
 long AAssetFile::tell() {

+ 2 - 1
src/core/PolyAndroidCore.cpp

@@ -331,6 +331,7 @@ void AndroidCore::extractResources(){
 			while(source->read(buffer, sizeof(char), 1) > 0){
 				dest->write(buffer,sizeof(char), 1);
 			}
+			bfileProvider->closeFile(dest);
 		}
 		
 		afileProvider->closeFile(source);
@@ -667,7 +668,7 @@ void AndroidCore::initKeyMap() {
 	keyMap[AKEYCODE_META_RIGHT] = KEY_RSUPER;
 	keyMap[AKEYCODE_META_LEFT] = KEY_LSUPER;
 
-	keyMap[AKEYCODE_HELP] = KEY_HELP;
+	keyMap[259] = KEY_HELP;
  	keyMap[AKEYCODE_SYSRQ] = KEY_PRINT;
 	keyMap[AKEYCODE_BREAK] = KEY_BREAK;
 	keyMap[AKEYCODE_MENU] = KEY_MENU;