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

Unified Diff: Source/core/frame/FrameView.cpp

Issue 346603005: Remove the old text autosizer (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase for landing Created 6 years, 5 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/core/dom/Document.cpp ('k') | Source/core/page/Page.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 9dda0b78d2daa9febf173c629ae0e45f484c5569..f844f8cf9c34bfb98272dba16c9593cbe69114b9 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -64,7 +64,6 @@
#include "core/rendering/RenderTheme.h"
#include "core/rendering/RenderView.h"
#include "core/rendering/RenderWidget.h"
-#include "core/rendering/TextAutosizer.h"
#include "core/rendering/compositing/CompositedLayerMapping.h"
#include "core/rendering/compositing/RenderLayerCompositor.h"
#include "core/rendering/style/RenderStyle.h"
@@ -347,17 +346,8 @@ void FrameView::setFrameRect(const IntRect& newRect)
// Autosized font sizes depend on the width of the viewing area.
bool autosizerNeedsUpdating = false;
- if (newRect.width() != oldRect.width()) {
- if (m_frame->isMainFrame() && m_frame->settings()->textAutosizingEnabled()) {
- autosizerNeedsUpdating = true;
- for (Frame* frame = m_frame.get(); frame; frame = frame->tree().traverseNext()) {
- if (!frame->isLocalFrame())
- continue;
- if (TextAutosizer* textAutosizer = toLocalFrame(frame)->document()->textAutosizer())
- textAutosizer->recalculateMultipliers();
- }
- }
- }
+ if (newRect.width() != oldRect.width() && m_frame->isMainFrame() && m_frame->settings()->textAutosizingEnabled())
+ autosizerNeedsUpdating = true;
ScrollView::setFrameRect(newRect);
@@ -792,20 +782,6 @@ void FrameView::performLayout(RenderObject* rootForThisLayout, bool inSubtreeLay
ResourceLoadPriorityOptimizer::resourceLoadPriorityOptimizer()->updateAllImageResourcePriorities();
- TextAutosizer* textAutosizer = frame().document()->textAutosizer();
- bool autosized;
- {
- AllowPaintInvalidationScope paintInvalidationAllowed(this);
- autosized = textAutosizer && textAutosizer->processSubtree(rootForThisLayout);
- }
-
- if (autosized && rootForThisLayout->needsLayout()) {
- TRACE_EVENT0("blink", "2nd layout due to Text Autosizing");
- UseCounter::count(*frame().document(), UseCounter::TextAutosizingLayout);
- rootForThisLayout->layout();
- gatherDebugLayoutRects(rootForThisLayout);
- }
-
lifecycle().advanceTo(DocumentLifecycle::AfterPerformLayout);
}
« no previous file with comments | « Source/core/dom/Document.cpp ('k') | Source/core/page/Page.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698