Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(309)

Unified Diff: Source/WebKit/chromium/src/WebViewImpl.cpp

Issue 13723004: Remove the ENABLE_TEXT_AUTOSIZING compile-time flag. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebKit/chromium/src/WebSettingsImpl.cpp ('k') | Source/WebKit/chromium/tests/WebFrameTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebKit/chromium/src/WebViewImpl.cpp
diff --git a/Source/WebKit/chromium/src/WebViewImpl.cpp b/Source/WebKit/chromium/src/WebViewImpl.cpp
index d6e3e007ac462651f07674deecac44c409fc3b48..fa11f1b3f9f8a52573f6a420c4d9a29c3b172208 100644
--- a/Source/WebKit/chromium/src/WebViewImpl.cpp
+++ b/Source/WebKit/chromium/src/WebViewImpl.cpp
@@ -1198,10 +1198,8 @@ void WebViewImpl::computeScaleAndScrollForHitRect(const WebRect& hitRect, AutoZo
// be allowed to manually pinch zoom in further if they desire.
const float defaultScaleWhenAlreadyLegible = m_minimumPageScaleFactor * doubleTapZoomAlreadyLegibleRatio;
float legibleScale = 1;
-#if ENABLE(TEXT_AUTOSIZING)
if (page() && page()->settings())
legibleScale *= page()->settings()->textAutosizingFontScaleFactor();
-#endif
if (legibleScale < defaultScaleWhenAlreadyLegible)
legibleScale = (scale == m_minimumPageScaleFactor) ? defaultScaleWhenAlreadyLegible : m_minimumPageScaleFactor;
@@ -2772,10 +2770,9 @@ void WebViewImpl::computeScaleAndScrollForFocusedNode(Node* focusedNode, float&
// the caret height will become minReadableCaretHeight (adjusted for dpi
// and font scale factor).
float targetScale = 1;
-#if ENABLE(TEXT_AUTOSIZING)
if (page() && page()->settings())
targetScale *= page()->settings()->textAutosizingFontScaleFactor();
-#endif
+
newScale = clampPageScaleFactorToLimits(minReadableCaretHeight * targetScale / caret.height);
const float deltaScale = newScale / pageScaleFactor();
« no previous file with comments | « Source/WebKit/chromium/src/WebSettingsImpl.cpp ('k') | Source/WebKit/chromium/tests/WebFrameTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698