Titanium JIRA Archive
Appcelerator Community (AC)

[AC-255] Back button on android webview crash

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionCannot Reproduce
Resolution Date2015-07-26T18:48:34.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsandroid, webview
ReporterDylan Rolfe
AssigneeRadamantis Torres-Lechuga
Created2015-07-24T00:39:51.000+0000
Updated2015-07-27T20:39:37.000+0000

Description

To reproduce: Create a new app. *index.xml*
<Alloy>
	<Window id="window"></Window>
</Alloy>
*index.js*
var html = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory + 'webview.html').read().text;
var webview = Titanium.UI.createWebView({
  html: html,
});
$.window.add(webview);
$.window.open();
Create a local html file in assets: webview.html (I used https://raw.githubusercontent.com/cbracco/html5-test-page/master/test.html as a test html) Run the app and hit the back button. The app crashes with this error: {noformat} [WARN] : UnimplementedWebViewApi: Unimplemented WebView method onKeyDown called from: android.webkit.WebView.onKeyDown(WebView.java:2178) [WARN] : IInputConnectionWrapper: showStatusIcon on inactive InputConnection [DEBUG] : Window: Window is closed normally. [ERROR] : WindowManager: [ERROR] : WindowManager: android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window android.widget.ZoomButtonsController$Container{428cdc18 V.E..... ......I. 0,0-768,97} that was originally added here [ERROR] : WindowManager: at android.view.ViewRootImpl.(ViewRootImpl.java:346) [ERROR] : WindowManager: at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java:248) [ERROR] : WindowManager: at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:69) [ERROR] : WindowManager: at android.widget.ZoomButtonsController.setVisible(ZoomButtonsController.java:371) [ERROR] : WindowManager: at com.android.org.chromium.android_webview.AwZoomControls.invokeZoomPicker(AwZoomControls.java:29) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.ContentViewCore.invokeZoomPicker(ContentViewCore.java:2818) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.ContentViewGestureHandler$1.onScroll(ContentViewGestureHandler.java:380) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.third_party.GestureDetector.onTouchEvent(GestureDetector.java:588) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.ContentViewGestureHandler.processTouchEvent(ContentViewGestureHandler.java:957) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.ContentViewGestureHandler.confirmTouchEvent(ContentViewGestureHandler.java:1007) [ERROR] : WindowManager: at com.android.org.chromium.content.browser.ContentViewCore.confirmTouchEvent(ContentViewCore.java:1363) [ERROR] : WindowManager: at com.android.org.chromium.base.SystemMessageHandler.nativeDoRunLoopOnce(Native Method) [ERROR] : WindowManager: at com.android.org.chromium.base.SystemMessageHandler.handleMessage(SystemMessageHandler.java:24) [ERROR] : WindowManager: at android.os.Handler.dispatchMessage(Handler.java:102) [ERROR] : WindowManager: at android.os.Looper.loop(Looper.java:136) [ERROR] : WindowManager: at android.app.ActivityThread.main(ActivityThread.java:5001) [ERROR] : WindowManager: at java.lang.reflect.Method.invokeNative(Native Method) [ERROR] : WindowManager: at java.lang.reflect.Method.invoke(Method.java:515) [ERROR] : WindowManager: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785) [ERROR] : WindowManager: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601) [ERROR] : WindowManager: at dalvik.system.NativeStart.main(Native Method) {noformat}

Comments

  1. Dylan Rolfe 2015-07-26

    Do you need more information from me to reproduce? It is happening everytime for me when testing on my Nexus 4. I haven't tried it in the emulator.
  2. Radamantis Torres-Lechuga 2015-07-27

    [~dylan] so far we can not reproduce the issue, please share more info with us that can help to replicate the problem Best

JSON Source