Closed glen-stephens closed 6 years ago
System.err: Calling js method onClick failed System.err: System.err: Error: java.lang.NullPointerException: Attempt to invoke virtual method 'void co.fitcom.fancywebview.CustomTabsServiceConnectionCallBack.setWebViewListener(co.fitcom.fancywebview.AdvancedWebViewListener)' on a null object reference System.err: co.fitcom.fancywebview.AdvancedWebView.setWebViewListener(AdvancedWebView.java:60) System.err: co.fitcom.fancywebview.AdvancedWebView.(AdvancedWebView.java:34) System.err: com.tns.Runtime.callJSMethodNative(Native Method) System.err: com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088) System.err: com.tns.Runtime.callJSMethodImpl(Runtime.java:970) System.err: com.tns.Runtime.callJSMethod(Runtime.java:957) System.err: com.tns.Runtime.callJSMethod(Runtime.java:941) System.err: com.tns.Runtime.callJSMethod(Runtime.java:933) System.err: com.tns.gen.java.lang.Object_button_19_32_ClickListenerImpl.onClick(Object_button_19_32_ClickListenerImpl.java:12) System.err: android.view.View.performClick(View.java:6207) System.err: android.widget.TextView.performClick(TextView.java:11094) System.err: android.view.View$PerformClick.run(View.java:23639) System.err: android.os.Handler.handleCallback(Handler.java:751) System.err: android.os.Handler.dispatchMessage(Handler.java:95) System.err: android.os.Looper.loop(Looper.java:154) System.err: android.app.ActivityThread.main(ActivityThread.java:6688) System.err: java.lang.reflect.Method.invoke(Native Method) System.err: com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1468) System.err: com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1358) System.err: File: "file:///data/data/com.myapp.myapp/files/app/tns_modules/nativescript-advanced-webview/advanced-webview.js, line: 43, column: 13
This is line 43 from the advanced-webview.js file: var wv = new co.fitcom.fancywebview.AdvancedWebView(activity, i);
Try version 3.0.0 which has been updated and demo app confirmed to work.
3.0.0
System.err: Calling js method onClick failed System.err: System.err: Error: java.lang.NullPointerException: Attempt to invoke virtual method 'void co.fitcom.fancywebview.CustomTabsServiceConnectionCallBack.setWebViewListener(co.fitcom.fancywebview.AdvancedWebViewListener)' on a null object reference System.err: co.fitcom.fancywebview.AdvancedWebView.setWebViewListener(AdvancedWebView.java:60) System.err: co.fitcom.fancywebview.AdvancedWebView.(AdvancedWebView.java:34)
System.err: com.tns.Runtime.callJSMethodNative(Native Method)
System.err: com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err: com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err: com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err: com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err: com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: com.tns.gen.java.lang.Object_button_19_32_ClickListenerImpl.onClick(Object_button_19_32_ClickListenerImpl.java:12)
System.err: android.view.View.performClick(View.java:6207)
System.err: android.widget.TextView.performClick(TextView.java:11094)
System.err: android.view.View$PerformClick.run(View.java:23639)
System.err: android.os.Handler.handleCallback(Handler.java:751)
System.err: android.os.Handler.dispatchMessage(Handler.java:95)
System.err: android.os.Looper.loop(Looper.java:154)
System.err: android.app.ActivityThread.main(ActivityThread.java:6688)
System.err: java.lang.reflect.Method.invoke(Native Method)
System.err: com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1468)
System.err: com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1358)
System.err: File: "file:///data/data/com.myapp.myapp/files/app/tns_modules/nativescript-advanced-webview/advanced-webview.js, line: 43, column: 13
This is line 43 from the advanced-webview.js file: var wv = new co.fitcom.fancywebview.AdvancedWebView(activity, i);