Skip to content

Commit 10507bd

Browse files
committed
Merge branch 'master' into trifonov/inspector-improvements
2 parents 532e2ea + b56c098 commit 10507bd

File tree

5 files changed

+9
-5
lines changed

5 files changed

+9
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
],
1212
"gradle": {
1313
"version": "4.10.2",
14-
"android": "3.2.1"
14+
"android": "3.3.0"
1515
},
1616
"android_ndk_version": "18b"
1717
}

test-app/app/src/debug/java/com/tns/NativeScriptSyncServiceSocketImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ public void run() {
165165

166166
validateData();
167167
if(runtime != null && doRefreshInt == DO_REFRESH_VALUE) {
168-
runtime.runScript(new File(NativeScriptSyncServiceSocketImpl.this.context.getFilesDir(), "internal/livesync.js"));
168+
runtime.runScript(new File(NativeScriptSyncServiceSocketImpl.this.context.getFilesDir(), "internal/livesync.js"), false);
169169
operationReportCode = OPERATION_END_REPORT_CODE;
170170
} else {
171171
operationReportCode = OPERATION_END_NO_REFRESH_REPORT_CODE;

test-app/build-tools/android-metadata-generator/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ buildscript {
1717
}
1818

1919
dependencies {
20-
classpath 'com.android.tools.build:gradle:3.2.1'
20+
classpath 'com.android.tools.build:gradle:3.3.0'
2121
}
2222
}
2323

test-app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ buildscript {
77
jcenter()
88
}
99
dependencies {
10-
classpath 'com.android.tools.build:gradle:3.2.1'
10+
classpath 'com.android.tools.build:gradle:3.3.0'
1111
}
1212
}
1313

test-app/runtime/src/main/java/com/tns/Runtime.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -590,6 +590,10 @@ public void runModule(File jsFile) throws NativeScriptException {
590590
}
591591

592592
public Object runScript(File jsFile) throws NativeScriptException {
593+
return this.runScript(jsFile, true);
594+
}
595+
596+
public Object runScript(File jsFile, final boolean waitForResultOnMainThread) throws NativeScriptException {
593597
Object result = null;
594598

595599
if (jsFile.exists() && jsFile.isFile()) {
@@ -621,7 +625,7 @@ public void run() {
621625
if (success) {
622626
synchronized (r) {
623627
try {
624-
if (arr[1] == null) {
628+
if (arr[1] == null && waitForResultOnMainThread) {
625629
r.wait();
626630
}
627631
} catch (InterruptedException e) {

0 commit comments

Comments
 (0)