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

Commit 1bf0456b authored by Shimeng (Simon) Wang's avatar Shimeng (Simon) Wang
Browse files

Treat restored defaultScale as overview.

Since usually restored defaultScale means previous scale is not saved.

issue: 4975315
Change-Id: Icc34469d0459fb5254567fe9f3cc5032b6349405
parent 63acea6a
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1111,6 +1111,12 @@ class ZoomManager {
                    mTextWrapScale = Math.max(mTextWrapScale, overviewScale);
                }
                reflowText = exceedsMinScaleIncrement(mTextWrapScale, scale);
            } else {
                // In case of restored scale, treat defaultScale as overview since
                // it usually means the previous scale is not saved.
                if (scale == mDefaultScale && settings.getLoadWithOverviewMode()) {
                    scale = overviewScale;
                }
            }
            mInitialZoomOverview = settings.getLoadWithOverviewMode() &&
                    !exceedsMinScaleIncrement(scale, overviewScale);