Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
bd5126e
make global object read only
Apr 27, 2015
a2d45b5
rename global functions
Apr 27, 2015
0ac8e24
remove unused file
Apr 27, 2015
4bf44bd
replace JS symbols with V8 hidden values in order to be compliant wit…
Apr 28, 2015
1c2db5a
Update changelog.
atanasovg Apr 29, 2015
60b262e
Do not extract assets if app was not updated
Apr 30, 2015
1bd2b8a
refactored all tests to work with jasmine
Plamen5kov Apr 28, 2015
3070210
fixed Do not extract assests if app was not updated
Apr 30, 2015
b245ca8
little change on appRoot path generation
Apr 30, 2015
26f6d99
do not wait for the debugger if none is coming
Apr 30, 2015
860a8da
fix typo
Apr 30, 2015
da489fb
added grunt automatization
Plamen5kov May 4, 2015
ab99929
added timeout to adb install command
Plamen5kov May 7, 2015
39941ad
fix gruntfile to work with references runtime and binding generator
Plamen5kov May 7, 2015
fef38a4
Merge pull request #59 from NativeScript/plamen5kov/run_tests_automat…
Plamen5kov May 12, 2015
105c54b
fixed hardcoded prefix value
Plamen5kov May 13, 2015
eed211f
fix compiler warnings
May 14, 2015
fb657f6
Merge pull request #66 from NativeScript/plamen5kov/prefix_refactoring
Plamen5kov May 15, 2015
87d50a1
fix issue #64
May 15, 2015
bdc0c6a
add unit test for issue #64
May 18, 2015
b077d99
run jasmine unit tests synchronously
May 18, 2015
8d277c8
refactor code to use pre-initialized jmethodIDs
May 18, 2015
efc0f0b
fix support for method overloads by argument type and/or argument count
May 18, 2015
a067294
tests for method overloads from js
May 18, 2015
8205a54
fix unit text
May 18, 2015
6cfe3de
fix unit test
May 18, 2015
2e62619
fix unit test
May 18, 2015
94dfaf9
simplify code
May 21, 2015
07f89e5
simplify code
May 21, 2015
15c6f5b
Fail tns build if ant is not using java 1.7
May 22, 2015
e451e61
fix buidl for java 1.8
May 25, 2015
f0c6188
change generated proxy objects to call unconditionally the JavaScript…
May 26, 2015
86b6816
revert changes
May 26, 2015
44d34aa
generate args array for constructors as well
May 26, 2015
52035ff
remove methodOverrides parameter as it not used anymore
May 27, 2015
8c72d96
fix android activity life cycle
May 29, 2015
cb21c83
use ref casts (build server uses Java 1.7)
May 29, 2015
f85e445
fix jni reference leaks (issue #72)
May 29, 2015
0978df8
add a check for 'extend' to fail when called as constructor
Jun 1, 2015
c2f295d
Use DexClassLoader instead of the MultiDex library.
atanasovg Jun 1, 2015
89393ab
Use the already created odex String.
atanasovg Jun 1, 2015
68d84eb
Merge pull request #82 from NativeScript/gatanasov/use-classloader
blagoev Jun 1, 2015
a692243
create the dex and odex dirs if not exists
blagoev Jun 1, 2015
a6ee7ea
add tests for issue #72
Jun 1, 2015
895f53e
fixed error handling bug
Plamen5kov Jun 2, 2015
35e46fa
Merge pull request #98 from NativeScript/plamen5kov/bug_fix
Plamen5kov Jun 2, 2015
90eadde
refactored: classNameSeparator is now a constant in binding generator…
Plamen5kov May 28, 2015
d6a3d31
fix: HTTP requests are executed serially instead of in parallel
tailsu Jun 2, 2015
aa7c1c0
Merge pull request #99 from NativeScript/sd/fix-http-serial-bug
Jun 3, 2015
bd3b48e
Merge pull request #97 from NativeScript/plamen5kov/separators
Jun 3, 2015
c2b61bf
fixed errors in binding generator tests due to constant CLASS_NAME_LO…
Plamen5kov Jun 3, 2015
233b851
Merge pull request #100 from NativeScript/plamen5kov/fix_binding_gene…
Plamen5kov Jun 3, 2015
5cdd431
Changed Lollipop theme to use spinner date/time pickers
Jun 3, 2015
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 20 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
Android Runtime Changelog
==============================
# Android Runtime Changelog

0.10.0 (2015, April 17)
==
## 1.0.0 (2015, April 29)

### New

* Updated the V8 version to 4.1.0.27.
* Re-implemented debugger support (no more spontaneous dead locks).

### Fixed

* An issue with the error reporting routine.

### Breaking Changes

* Renamed global functions:
* `__log` (was `Log`)
* `__debugbreak` (was `waitForDebugger`)
* `__enableVerboseLogging` (was `enableVerboseLogging`)
* `__disableVerboseLogging` (was `disableVerboseLogging`)
* `__exit` (was `fail`)

## 0.10.0 (2015, April 17)

### New

* Added Dynamic Generator for binding proxies. This boosts the initial loading time, especially on Android 5.0+ devices.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,4 @@ public interface NativeScriptHashCodeProvider
int hashCode__super();

boolean equals__super(Object other);

// void setNativeScriptOverrides(String[] overrides);

void setNativeScriptOverride(String override);
}
240 changes: 49 additions & 191 deletions binding-generator/Generator/src/com/tns/bindings/Dump.java

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public String generateProxy(String proxyName, Class<?> classToProxy, HashSet<Str
aw.visitEnd();
byte[] generatedBytes = aw.toByteArray();

String proxyFileName = classToProxy.getName().replace('$', '_') + "-" + proxyName;
String proxyFileName = classToProxy.getName().replace('$', '_') + Dump.CLASS_NAME_LOCATION_SEPARATOR + proxyName;
if (proxyThumb != null)
{
proxyFileName += "-" + proxyThumb;
Expand Down
16 changes: 16 additions & 0 deletions binding-generator/Tester/src/com/proxy/TargetObject.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,22 @@ public void methodWithStringArg(String a)
Log.d("Proxy.Tester", "methodWithStringArg: " + a);
}

public void methodWithOverload(int a)
{
Log.d("Proxy.Tester", "methodWithOverload: " + a);
}

public void methodWithOverload(byte a)
{
Log.d("Proxy.Tester", "methodWithOverload: " + a);
}

public void methodWithOverload()
{
arg = null;
Log.d("Proxy.Tester", "methodWithOverload no args");
}

public void methodWithIntArg(int a)
{
arg = a;
Expand Down

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions build/project-template/custom_rules.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="custom_logic_for_metadata_generation" default="-post-compile">

<condition property="supportedJavaVersion">
<or>
<equals arg1="1.7" arg2="${ant.java.version}"/>
<equals arg1="1.8" arg2="${ant.java.version}"/>
</or>
</condition>

<fail message="Java 1.7 or newer is required. Check if the JAVA_HOME environment variable points to JDK 1.7 or newer" unless="supportedJavaVersion"/>

<property name="path_to_metadata" value="./assets/metadata"/>
<property name="ns.project.lib" value="../../lib/Android" />

Expand Down
15 changes: 14 additions & 1 deletion build/project-template/res/values-v21/styles.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- Application theme -->
<style name="AppTheme" parent="android:Theme.Material.Light">
</style>
<item name="android:datePickerStyle">@style/SpinnerDatePicker</item>
<item name="android:timePickerStyle">@style/SpinnerTimePicker</item>
</style>

<!-- Default style for DatePicker - in spinner mode -->
<style name="SpinnerDatePicker" parent="android:Widget.Material.Light.DatePicker">
<item name="android:datePickerMode">spinner</item>
</style>

<!-- Default style for TimePicker - in spinner mode -->
<style name="SpinnerTimePicker" parent="android:Widget.Material.Light.TimePicker">
<item name="android:timePickerMode">spinner</item>
</style>
</resources>
24 changes: 5 additions & 19 deletions build/project-template/res/values/styles.xml
Original file line number Diff line number Diff line change
@@ -1,20 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<!--
Base application theme, dependent on API level. This theme is replaced
by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
-->
<style name="AppBaseTheme" parent="android:Theme.Holo.Light">
<!--
Theme customizations available in newer API levels can go in
res/values-vXX/styles.xml, while customizations related to
backward-compatibility can go here.
-->
</style>

<!-- Application theme. -->
<style name="AppTheme" parent="AppBaseTheme">
<!-- All customizations that are NOT specific to a particular API-level can go here. -->
</style>
</resources>
<resources>
<!-- Application theme -->
<style name="AppTheme" parent="android:Theme.Holo.Light">
</style>
</resources>
22 changes: 20 additions & 2 deletions gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,19 @@ module.exports = function(grunt) {
},
runMetadataGenerator: {
cmd: "./node_modules/.bin/generate-metadata " + localCfg.libsDir + " ./dist/framework/assets/metadata"
}
},
runTests: {
cmd: "npm install && grunt --verbose",
cwd: "./test-app"
},
antCleanBindingGenerator: {
cmd: "ant clean",
cwd: "./binding-generator/Generator/"
},
antCleanRunTime: {
cmd: "ant clean",
cwd: "./src/"
},
}
});

Expand All @@ -206,7 +218,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks("grunt-replace");

grunt.registerTask("generateRuntime", [
"exec:generateRuntime"
"exec:generateRuntime"
]);

grunt.registerTask("generateMetadata", [
Expand All @@ -230,6 +242,12 @@ module.exports = function(grunt) {
return [];
}
})());

grunt.registerTask("test", [
"exec:antCleanBindingGenerator",
"exec:antCleanRunTime",
"exec:runTests"
]);

grunt.registerTask("default", [
"clean:build",
Expand Down
4 changes: 2 additions & 2 deletions src/assets/app/bootstrap.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
global.__onUncaughtError = function(error){
if(error.nativeException){
Log("err.message: " + error.message);
Log("err.stackTrace: " + error.stackTrace);
__log("err.message: " + error.message);
__log("err.stackTrace: " + error.stackTrace);
// false == do not continue execution
return false;
}
Expand Down
4 changes: 2 additions & 2 deletions src/assets/internal/prepareExtend.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ var __extends = function(Child, Parent) {
}

function extend(child, parent) {
Log("TS extend called");
__log("TS extend called");
if (!child.__extended) {
child.__extended = parent.extend(child.name, child.prototype);
}
Expand All @@ -66,7 +66,7 @@ var __extends = function(Child, Parent) {
};

Parent.__activityExtend = function(parent, name, implementationObject) {
Log("__activityExtend called");
__log("__activityExtend called");
return parent.extend(name, implementationObject);
};

Expand Down
2 changes: 1 addition & 1 deletion src/jni/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_CPPFLAGS += -std=c++11
LOCAL_MODULE := NativeScript
LOCAL_SRC_FILES := com_tns_Platform.cpp com_tns_JsDebugger.cpp com_tns_AssetExtractor.cpp \
LOCAL_SRC_FILES := com_tns_Platform.cpp com_tns_JsDebugger.cpp com_tns_AssetExtractor.cpp com_tns_NativeScriptActity.cpp \
JEnv.cpp DirectBuffer.cpp \
JsDebugger.cpp \
NativeScriptRuntime.cpp MetadataNode.cpp MetadataTreeNode.cpp MetadataReader.cpp \
Expand Down
Loading