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

Commit 2ddb4c85 authored by Mangesh Ghiware's avatar Mangesh Ghiware Committed by Android (Google) Code Review
Browse files

Merge "Fix issue with site-specific display density getting stuck."

parents f6a2ae37 6f2db8e7
Loading
Loading
Loading
Loading
+1 −5
Original line number Diff line number Diff line
@@ -2396,11 +2396,7 @@ public final class WebViewCore {
        // adjust the default scale to match the densityDpi
        float adjust = 1.0f;
        if (mViewportDensityDpi == -1) {
            // convert default zoom scale to a integer (percentage) to avoid any
            // issues with floating point comparisons
            if (mWebView != null && (int)(mWebView.getDefaultZoomScale() * 100) != 100) {
                adjust = mWebView.getDefaultZoomScale();
            }
            adjust = mContext.getResources().getDisplayMetrics().density;
        } else if (mViewportDensityDpi > 0) {
            adjust = (float) mContext.getResources().getDisplayMetrics().densityDpi
                    / mViewportDensityDpi;