Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a559e8b6 authored by Derek Sollenberger's avatar Derek Sollenberger Committed by Android (Google) Code Review
Browse files

Merge "fix NullPointerException caused by inflating XML Webview that is defined to be non-visible."

parents 71afcc5f f39d2660
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -3970,7 +3970,9 @@ public class WebView extends AbsoluteLayout
    @Override
    @Override
    protected void onVisibilityChanged(View changedView, int visibility) {
    protected void onVisibilityChanged(View changedView, int visibility) {
        super.onVisibilityChanged(changedView, visibility);
        super.onVisibilityChanged(changedView, visibility);
        if (visibility != View.VISIBLE) {
        // The zoomManager may be null if the webview is created from XML that
        // specifies the view's visibility param as not visible (see http://b/2794841)
        if (visibility != View.VISIBLE && mZoomManager != null) {
            mZoomManager.dismissZoomPicker();
            mZoomManager.dismissZoomPicker();
        }
        }
    }
    }