diff --git a/.gitignore b/.gitignore index 86f21d8e..43f2d0d8 100644 --- a/.gitignore +++ b/.gitignore @@ -58,3 +58,10 @@ fastlane/screenshots # https://github.com/johnno1962/injectionforxcode iOSInjectionProject/ + +## ndk build + +Source/Android/luascriptcore/.externalNativeBuild/ + +## idea / Android Studio +*.iml diff --git a/Sample/Android/.gitignore b/Sample/Android/.gitignore old mode 100644 new mode 100755 index c6cbe562..4330062b --- a/Sample/Android/.gitignore +++ b/Sample/Android/.gitignore @@ -6,3 +6,7 @@ .DS_Store /build /captures +.idea +/local.properties +/gradle.properties +.externalNativeBuild \ No newline at end of file diff --git a/Sample/Android/.idea/compiler.xml b/Sample/Android/.idea/compiler.xml deleted file mode 100644 index 96cc43ef..00000000 --- a/Sample/Android/.idea/compiler.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/copyright/profiles_settings.xml b/Sample/Android/.idea/copyright/profiles_settings.xml deleted file mode 100644 index e7bedf33..00000000 --- a/Sample/Android/.idea/copyright/profiles_settings.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/Sample/Android/.idea/encodings.xml b/Sample/Android/.idea/encodings.xml deleted file mode 100644 index 97626ba4..00000000 --- a/Sample/Android/.idea/encodings.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/gradle.xml b/Sample/Android/.idea/gradle.xml deleted file mode 100644 index 7e8f88b8..00000000 --- a/Sample/Android/.idea/gradle.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/libraries/hamcrest_core_1_3.xml b/Sample/Android/.idea/libraries/hamcrest_core_1_3.xml deleted file mode 100644 index 157e3f34..00000000 --- a/Sample/Android/.idea/libraries/hamcrest_core_1_3.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/libraries/junit_4_12.xml b/Sample/Android/.idea/libraries/junit_4_12.xml deleted file mode 100644 index 305df301..00000000 --- a/Sample/Android/.idea/libraries/junit_4_12.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/misc.xml b/Sample/Android/.idea/misc.xml deleted file mode 100644 index 5d199810..00000000 --- a/Sample/Android/.idea/misc.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/modules.xml b/Sample/Android/.idea/modules.xml deleted file mode 100644 index 10dced61..00000000 --- a/Sample/Android/.idea/modules.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/runConfigurations.xml b/Sample/Android/.idea/runConfigurations.xml deleted file mode 100644 index 7f68460d..00000000 --- a/Sample/Android/.idea/runConfigurations.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Sample/Android/.idea/workspace.xml b/Sample/Android/.idea/workspace.xml deleted file mode 100644 index 33f88e5d..00000000 --- a/Sample/Android/.idea/workspace.xml +++ /dev/null @@ -1,3964 +0,0 @@ - - - - - - compat-android-23 - - - - - - @style/AppTheme - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 1473771804567 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - file://$PROJECT_DIR$/app/src/main/java/cn/vimfung/luascriptcore/sample/Console.java - 10 - - - - file://$PROJECT_DIR$/../../Source/lua-common/LuaExportsTypeManager.cpp - 464 - - - file://$PROJECT_DIR$/../../Source/Android/luascriptcore/src/main/jni/LuaJavaExportPropertyDescriptor.cpp - 58 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/Android.iml b/Sample/Android/Android.iml deleted file mode 100644 index 3a188e20..00000000 --- a/Sample/Android/Android.iml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/app/app.iml b/Sample/Android/app/app.iml deleted file mode 100644 index fb32fe9a..00000000 --- a/Sample/Android/app/app.iml +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Sample/Android/app/build.gradle b/Sample/Android/app/build.gradle old mode 100644 new mode 100755 index 3f2f4f6d..2a58788b --- a/Sample/Android/app/build.gradle +++ b/Sample/Android/app/build.gradle @@ -2,7 +2,7 @@ apply plugin: 'com.android.application' android { compileSdkVersion 24 - buildToolsVersion '25.0.0' + buildToolsVersion '26.0.2' defaultConfig { applicationId "cn.vimfung.luascriptcore.sample" diff --git a/Sample/Android/build.gradle b/Sample/Android/build.gradle old mode 100644 new mode 100755 index f7a00207..55ac333a --- a/Sample/Android/build.gradle +++ b/Sample/Android/build.gradle @@ -3,11 +3,15 @@ buildscript { repositories { jcenter() + maven { + url 'https://maven.google.com/' + name 'Google' + } } dependencies { - classpath 'com.android.tools.build:gradle:2.2.2' - classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2' - classpath 'com.github.dcendents:android-maven-gradle-plugin:1.4.1' + classpath 'com.android.tools.build:gradle:3.0.1' + classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.3' + classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } @@ -16,6 +20,10 @@ buildscript { allprojects { repositories { jcenter() + maven { + url 'https://maven.google.com/' + name 'Google' + } } } diff --git a/Sample/Android/gradle.properties b/Sample/Android/gradle.properties deleted file mode 100644 index 3a35f6d3..00000000 --- a/Sample/Android/gradle.properties +++ /dev/null @@ -1,19 +0,0 @@ -# Project-wide Gradle settings. - -# IDE (e.g. Android Studio) users: -# Gradle settings configured through the IDE *will override* -# any settings specified in this file. - -# For more details on how to configure your build environment visit -# http://www.gradle.org/docs/current/userguide/build_environment.html - -# Specifies the JVM arguments used for the daemon process. -# The setting is particularly useful for tweaking memory settings. -# Default value: -Xmx10248m -XX:MaxPermSize=256m -# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 - -# When configured, Gradle will run in incubating parallel mode. -# This option should only be used with decoupled projects. More details, visit -# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects -# org.gradle.parallel=true -#android.useDeprecatedNdk=true \ No newline at end of file diff --git a/Sample/Android/gradle/wrapper/gradle-wrapper.properties b/Sample/Android/gradle/wrapper/gradle-wrapper.properties index 19bdcc19..2f838ed2 100644 --- a/Sample/Android/gradle/wrapper/gradle-wrapper.properties +++ b/Sample/Android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Thu Mar 16 16:45:07 CST 2017 +#Wed Jan 24 16:10:12 CST 2018 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip diff --git a/Sample/Android/local.properties b/Sample/Android/local.properties deleted file mode 100644 index e4db29ca..00000000 --- a/Sample/Android/local.properties +++ /dev/null @@ -1,12 +0,0 @@ -## This file is automatically generated by Android Studio. -# Do not modify this file -- YOUR CHANGES WILL BE ERASED! -# -# This file must *NOT* be checked into Version Control Systems, -# as it contains information specific to your local configuration. -# -# Location of the SDK. This is only used by Gradle. -# For customization when using a Version Control System, please read the -# header note. -#Tue Sep 13 21:03:26 CST 2016 -ndk.dir=/Users/vimfung/Library/Android/sdk/ndk-bundle -sdk.dir=/Users/vimfung/Library/Android/sdk \ No newline at end of file diff --git a/Source/Android/.gitignore b/Source/Android/.gitignore old mode 100644 new mode 100755 index c6cbe562..57fee1c2 --- a/Source/Android/.gitignore +++ b/Source/Android/.gitignore @@ -1,8 +1,12 @@ *.iml .gradle +/.idea /local.properties /.idea/workspace.xml /.idea/libraries .DS_Store /build /captures +/local.properties +/gradle.properties +/.externalNativeBuild \ No newline at end of file diff --git a/Source/Android/.gradle/2.14.1/taskArtifacts/cache.properties.lock b/Source/Android/.gradle/2.14.1/taskArtifacts/cache.properties.lock index ca08494c..742a0c9e 100644 Binary files a/Source/Android/.gradle/2.14.1/taskArtifacts/cache.properties.lock and b/Source/Android/.gradle/2.14.1/taskArtifacts/cache.properties.lock differ diff --git a/Source/Android/.gradle/2.14.1/taskArtifacts/fileHashes.bin b/Source/Android/.gradle/2.14.1/taskArtifacts/fileHashes.bin index 49bfe6e7..e1d3a610 100644 Binary files a/Source/Android/.gradle/2.14.1/taskArtifacts/fileHashes.bin and b/Source/Android/.gradle/2.14.1/taskArtifacts/fileHashes.bin differ diff --git a/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshots.bin b/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshots.bin index 5482a71d..f0badd27 100644 Binary files a/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshots.bin and b/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshots.bin differ diff --git a/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshotsToTreeSnapshotsIndex.bin b/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshotsToTreeSnapshotsIndex.bin index 1ae0fa9a..d6cbedc0 100644 Binary files a/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshotsToTreeSnapshotsIndex.bin and b/Source/Android/.gradle/2.14.1/taskArtifacts/fileSnapshotsToTreeSnapshotsIndex.bin differ diff --git a/Source/Android/.gradle/2.14.1/taskArtifacts/taskArtifacts.bin b/Source/Android/.gradle/2.14.1/taskArtifacts/taskArtifacts.bin index 5f4bba2a..a1f93240 100644 Binary files a/Source/Android/.gradle/2.14.1/taskArtifacts/taskArtifacts.bin and b/Source/Android/.gradle/2.14.1/taskArtifacts/taskArtifacts.bin differ diff --git a/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localClassSetAnalysis/localClassSetAnalysis.lock b/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localClassSetAnalysis/localClassSetAnalysis.lock index 41fa7689..20a19f8c 100644 Binary files a/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localClassSetAnalysis/localClassSetAnalysis.lock and b/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localClassSetAnalysis/localClassSetAnalysis.lock differ diff --git a/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localJarClasspathSnapshot/localJarClasspathSnapshot.lock b/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localJarClasspathSnapshot/localJarClasspathSnapshot.lock index 6e83b827..c0875f14 100644 Binary files a/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localJarClasspathSnapshot/localJarClasspathSnapshot.lock and b/Source/Android/.gradle/2.14.1/tasks/_luascriptcore_compileReleaseJavaWithJavac/localJarClasspathSnapshot/localJarClasspathSnapshot.lock differ diff --git a/Source/Android/.idea/.name b/Source/Android/.idea/.name deleted file mode 100644 index 1429c13e..00000000 --- a/Source/Android/.idea/.name +++ /dev/null @@ -1 +0,0 @@ -Android \ No newline at end of file diff --git a/Source/Android/.idea/compiler.xml b/Source/Android/.idea/compiler.xml deleted file mode 100644 index 96cc43ef..00000000 --- a/Source/Android/.idea/compiler.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/copyright/profiles_settings.xml b/Source/Android/.idea/copyright/profiles_settings.xml deleted file mode 100644 index e7bedf33..00000000 --- a/Source/Android/.idea/copyright/profiles_settings.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/Source/Android/.idea/encodings.xml b/Source/Android/.idea/encodings.xml deleted file mode 100644 index 97626ba4..00000000 --- a/Source/Android/.idea/encodings.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/gradle.xml b/Source/Android/.idea/gradle.xml deleted file mode 100644 index caf1db14..00000000 --- a/Source/Android/.idea/gradle.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/misc.xml b/Source/Android/.idea/misc.xml deleted file mode 100644 index 5d199810..00000000 --- a/Source/Android/.idea/misc.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/modules.xml b/Source/Android/.idea/modules.xml deleted file mode 100644 index 2fd7f57d..00000000 --- a/Source/Android/.idea/modules.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/runConfigurations.xml b/Source/Android/.idea/runConfigurations.xml deleted file mode 100644 index 7f68460d..00000000 --- a/Source/Android/.idea/runConfigurations.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/Source/Android/.idea/workspace.xml b/Source/Android/.idea/workspace.xml deleted file mode 100644 index 78a8df88..00000000 --- a/Source/Android/.idea/workspace.xml +++ /dev/null @@ -1,2734 +0,0 @@ - - - - - - compat-android-13 - - - - - - @style/Theme.AppCompat.Light.NoActionBar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 1473771235507 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Source/Android/Android.iml b/Source/Android/Android.iml deleted file mode 100644 index 3a188e20..00000000 --- a/Source/Android/Android.iml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Source/Android/build.gradle b/Source/Android/build.gradle old mode 100644 new mode 100755 index d2774fe1..7901d8b6 --- a/Source/Android/build.gradle +++ b/Source/Android/build.gradle @@ -3,11 +3,15 @@ buildscript { repositories { jcenter() + maven { + url 'https://maven.google.com/' + name 'Google' + } } dependencies { - classpath 'com.android.tools.build:gradle:2.2.3' - classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2' - classpath 'com.github.dcendents:android-maven-gradle-plugin:1.4.1' + classpath 'com.android.tools.build:gradle:3.0.1' + classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.3' + classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files @@ -17,6 +21,10 @@ buildscript { allprojects { repositories { jcenter() + maven { + url 'https://maven.google.com/' + name 'Google' + } } } diff --git a/Source/Android/gradle.properties b/Source/Android/gradle.properties deleted file mode 100644 index d5c6ffea..00000000 --- a/Source/Android/gradle.properties +++ /dev/null @@ -1,19 +0,0 @@ -# Project-wide Gradle settings. - -# IDE (e.g. Android Studio) users: -# Gradle settings configured through the IDE *will override* -# any settings specified in this file. - -# For more details on how to configure your build environment visit -# http://www.gradle.org/docs/current/userguide/build_environment.html - -# Specifies the JVM arguments used for the daemon process. -# The setting is particularly useful for tweaking memory settings. -# Default value: -Xmx10248m -XX:MaxPermSize=256m -# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 - -# When configured, Gradle will run in incubating parallel mode. -# This option should only be used with decoupled projects. More details, visit -# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects -# org.gradle.parallel=true -# android.useDeprecatedNdk=true \ No newline at end of file diff --git a/Source/Android/gradle/wrapper/gradle-wrapper.properties b/Source/Android/gradle/wrapper/gradle-wrapper.properties index 8d3c0b39..d20a89ca 100644 --- a/Source/Android/gradle/wrapper/gradle-wrapper.properties +++ b/Source/Android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Wed Aug 24 15:54:25 CST 2016 +#Thu Jan 25 11:03:04 CST 2018 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip diff --git a/Source/Android/luascriptcore/build.gradle b/Source/Android/luascriptcore/build.gradle old mode 100644 new mode 100755 index ad054b8b..a227cb5f --- a/Source/Android/luascriptcore/build.gradle +++ b/Source/Android/luascriptcore/build.gradle @@ -1,2 +1,6 @@ apply from: './compile.gradle' -//apply from: './compile-5.1.5.gradle' //lua 5.1.5 版本 \ No newline at end of file +//apply from: './compile-5.1.5.gradle' //lua 5.1.5 版本 + +android { + buildToolsVersion '26.0.2' +} \ No newline at end of file diff --git a/Source/Android/luascriptcore/compile-5.1.5.gradle b/Source/Android/luascriptcore/compile-5.1.5.gradle old mode 100644 new mode 100755 index 139dfee4..cf0de00b --- a/Source/Android/luascriptcore/compile-5.1.5.gradle +++ b/Source/Android/luascriptcore/compile-5.1.5.gradle @@ -2,7 +2,7 @@ apply plugin: 'com.android.library' android { compileSdkVersion 24 - buildToolsVersion '25.0.0' + buildToolsVersion '26.0.2' defaultConfig { minSdkVersion 13 diff --git a/Source/Android/luascriptcore/compile.gradle b/Source/Android/luascriptcore/compile.gradle old mode 100644 new mode 100755 index 6e739d98..c909fd72 --- a/Source/Android/luascriptcore/compile.gradle +++ b/Source/Android/luascriptcore/compile.gradle @@ -2,7 +2,7 @@ apply plugin: 'com.android.library' android { compileSdkVersion 24 - buildToolsVersion '25.0.0' + buildToolsVersion '26.0.2' defaultConfig { minSdkVersion 13 diff --git a/Source/Android/luascriptcore/src/main/java/cn/vimfung/luascriptcore/LuaExportTypeManager.java b/Source/Android/luascriptcore/src/main/java/cn/vimfung/luascriptcore/LuaExportTypeManager.java index 19e6d750..c6be3794 100644 --- a/Source/Android/luascriptcore/src/main/java/cn/vimfung/luascriptcore/LuaExportTypeManager.java +++ b/Source/Android/luascriptcore/src/main/java/cn/vimfung/luascriptcore/LuaExportTypeManager.java @@ -298,37 +298,37 @@ void setterMethodRoute(LuaContext context, Object instance, String fieldName, Lu */ private Object getArgValue(Class argType, LuaValue value) { - if (argType.isAssignableFrom(int.class)) + if (int.class.isAssignableFrom(argType)) { return value.toInteger(); } - else if (argType.isAssignableFrom(double.class)) + else if (double.class.isAssignableFrom(argType)) { return value.toDouble(); } - else if (argType.isAssignableFrom(boolean.class)) + else if (boolean.class.isAssignableFrom(argType)) { return value.toBoolean(); } - else if (argType.isAssignableFrom(String.class)) + else if (String.class.isAssignableFrom(argType)) { return value.toString(); } - else if (argType.isAssignableFrom(byte[].class)) + else if (byte[].class.isAssignableFrom(argType)) { return value.toByteArray(); } - else if (argType.isAssignableFrom(ArrayList.class)) + else if (ArrayList.class.isAssignableFrom(argType)) { return value.toArrayList(); } - else if (argType.isAssignableFrom(HashMap.class)) + else if (HashMap.class.isAssignableFrom(argType)) { return value.toHashMap(); } else if (argType.isArray()) { - if (argType.isAssignableFrom(int[].class)) + if (int[].class.isAssignableFrom(argType)) { //转换数组中的Double型为整型 ArrayList itemArr = value.toArrayList(); @@ -339,7 +339,7 @@ else if (argType.isArray()) } return items; } - else if (argType.isAssignableFrom(Integer[].class)) + else if (Integer[].class.isAssignableFrom(argType)) { //转换数组中的Double型为整型 ArrayList itemArr = value.toArrayList(); @@ -352,11 +352,11 @@ else if (argType.isAssignableFrom(Integer[].class)) return items; } - else if (argType.isAssignableFrom(Double[].class)) + else if (Double[].class.isAssignableFrom(argType)) { return value.toArrayList().toArray(new Double[0]); } - else if (argType.isAssignableFrom(double[].class)) + else if (double[].class.isAssignableFrom(argType)) { ArrayList itemArr = value.toArrayList(); double items[] = new double[itemArr.size()]; @@ -367,11 +367,11 @@ else if (argType.isAssignableFrom(double[].class)) return items; } - else if (argType.isAssignableFrom(Boolean[].class)) + else if (Boolean[].class.isAssignableFrom(argType)) { return value.toArrayList().toArray(new Boolean[0]); } - else if (argType.isAssignableFrom(boolean[].class)) + else if (boolean[].class.isAssignableFrom(argType)) { ArrayList itemArr = value.toArrayList(); boolean items[] = new boolean[itemArr.size()];