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

Unified Diff: Source/core/dom/Range.cpp

Issue 57643004: Pass RenderStyle / RenderObject by reference in more places (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase on master Created 7 years, 1 month 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/Element.cpp ('k') | Source/core/frame/animation/AnimationBase.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Range.cpp
diff --git a/Source/core/dom/Range.cpp b/Source/core/dom/Range.cpp
index 5b2d161cce657891427440ca83e038f4aaf3e6df..db24f8986e1bc58999d14d2f4dcb43612704a35e 100644
--- a/Source/core/dom/Range.cpp
+++ b/Source/core/dom/Range.cpp
@@ -1861,19 +1861,19 @@ void Range::getBorderAndTextQuads(Vector<FloatQuad>& quads) const
if (RenderBoxModelObject* renderBoxModelObject = toElement(node)->renderBoxModelObject()) {
Vector<FloatQuad> elementQuads;
renderBoxModelObject->absoluteQuads(elementQuads);
- m_ownerDocument->adjustFloatQuadsForScrollAndAbsoluteZoom(elementQuads, renderBoxModelObject);
+ m_ownerDocument->adjustFloatQuadsForScrollAndAbsoluteZoom(elementQuads, *renderBoxModelObject);
quads.append(elementQuads);
}
}
} else if (node->isTextNode()) {
if (RenderObject* renderer = toText(node)->renderer()) {
- RenderText* renderText = toRenderText(renderer);
+ RenderText& renderText = toRenderText(*renderer);
int startOffset = (node == startContainer) ? m_start.offset() : 0;
int endOffset = (node == endContainer) ? m_end.offset() : INT_MAX;
Vector<FloatQuad> textQuads;
- renderText->absoluteQuadsForRange(textQuads, startOffset, endOffset);
+ renderText.absoluteQuadsForRange(textQuads, startOffset, endOffset);
m_ownerDocument->adjustFloatQuadsForScrollAndAbsoluteZoom(textQuads, renderText);
quads.append(textQuads);
« no previous file with comments | « Source/core/dom/Element.cpp ('k') | Source/core/frame/animation/AnimationBase.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698