|
2 | 2 |
|
3 | 3 | import android.app.Application; |
4 | 4 |
|
5 | | -@JavaScriptImplementation(javaScriptFile = "./MyApp.js") |
6 | | -public class NativeScriptApplication extends android.app.Application implements com.tns.NativeScriptHashCodeProvider { |
| 5 | +public class NativeScriptApplication extends android.app.Application { |
7 | 6 |
|
8 | 7 | private static NativeScriptApplication thiz; |
9 | 8 |
|
10 | | - public NativeScriptApplication() |
11 | | - { |
12 | | - //android.os.Debug.waitForDebugger(); |
| 9 | + public NativeScriptApplication() { |
13 | 10 | thiz = this; |
14 | 11 | } |
15 | 12 |
|
16 | 13 | public void onCreate() { |
| 14 | + super.onCreate(); |
17 | 15 | new RuntimeHelper(this).initRuntime(); |
18 | | - if (Runtime.isInitialized()) { |
19 | | - java.lang.Object[] params = null; |
20 | | - com.tns.Runtime.callJSMethod(this, "onCreate", void.class, params); |
21 | | - } else { |
22 | | - super.onCreate(); |
23 | | - } |
24 | | - } |
25 | | - |
26 | | - public void onLowMemory() { |
27 | | - if (Runtime.isInitialized()) { |
28 | | - java.lang.Object[] params = null; |
29 | | - com.tns.Runtime.callJSMethod(this, "onLowMemory", void.class, params); |
30 | | - } else { |
31 | | - super.onLowMemory(); |
32 | | - } |
33 | | - } |
34 | | - |
35 | | - public void onTrimMemory(int level) { |
36 | | - if (Runtime.isInitialized()) { |
37 | | - java.lang.Object[] params = new Object[1]; |
38 | | - params[0] = level; |
39 | | - com.tns.Runtime.callJSMethod(this, "onTrimMemory", void.class, params); |
40 | | - } else { |
41 | | - super.onTrimMemory(level); |
42 | | - } |
43 | | - } |
44 | | - |
45 | | - public boolean equals__super(java.lang.Object other) { |
46 | | - return super.equals(other); |
47 | | - } |
48 | | - |
49 | | - public int hashCode__super() { |
50 | | - return super.hashCode(); |
51 | 16 | } |
52 | 17 |
|
53 | 18 | public static Application getInstance() { |
|
0 commit comments