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

Side by Side Diff: sky/engine/core/rendering/RenderInline.cpp

Issue 899753003: Walk render tree instead of render layers for paint. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: address review comments Created 5 years, 10 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 unified diff | Download patch
« no previous file with comments | « sky/engine/core/rendering/RenderInline.h ('k') | sky/engine/core/rendering/RenderLayer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 163
164 return caretRect; 164 return caretRect;
165 } 165 }
166 166
167 void RenderInline::addChild(RenderObject* newChild, RenderObject* beforeChild) 167 void RenderInline::addChild(RenderObject* newChild, RenderObject* beforeChild)
168 { 168 {
169 RenderBoxModelObject::addChild(newChild, beforeChild); 169 RenderBoxModelObject::addChild(newChild, beforeChild);
170 newChild->setNeedsLayoutAndPrefWidthsRecalc(); 170 newChild->setNeedsLayoutAndPrefWidthsRecalc();
171 } 171 }
172 172
173 void RenderInline::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset) 173 void RenderInline::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset, V ector<RenderBox*>& layers)
174 { 174 {
175 m_lineBoxes.paint(this, paintInfo, paintOffset); 175 m_lineBoxes.paint(this, paintInfo, paintOffset, layers);
176 } 176 }
177 177
178 template<typename GeneratorContext> 178 template<typename GeneratorContext>
179 void RenderInline::generateLineBoxRects(GeneratorContext& yield) const 179 void RenderInline::generateLineBoxRects(GeneratorContext& yield) const
180 { 180 {
181 if (!alwaysCreateLineBoxes()) 181 if (!alwaysCreateLineBoxes())
182 generateCulledLineBoxRects(yield, this); 182 generateCulledLineBoxRects(yield, this);
183 else if (InlineFlowBox* curr = firstLineBox()) { 183 else if (InlineFlowBox* curr = firstLineBox()) {
184 for (; curr; curr = curr->nextLineBox()) 184 for (; curr; curr = curr->nextLineBox())
185 yield(FloatRect(curr->topLeft(), curr->size())); 185 yield(FloatRect(curr->topLeft(), curr->size()));
(...skipping 581 matching lines...) Expand 10 before | Expand all | Expand 10 after
767 767
768 void RenderInline::addFocusRingRects(Vector<IntRect>& rects, const LayoutPoint& additionalOffset, const RenderLayerModelObject* paintContainer) const 768 void RenderInline::addFocusRingRects(Vector<IntRect>& rects, const LayoutPoint& additionalOffset, const RenderLayerModelObject* paintContainer) const
769 { 769 {
770 AbsoluteRectsIgnoringEmptyRectsGeneratorContext context(rects, additionalOff set); 770 AbsoluteRectsIgnoringEmptyRectsGeneratorContext context(rects, additionalOff set);
771 generateLineBoxRects(context); 771 generateLineBoxRects(context);
772 772
773 addChildFocusRingRects(rects, additionalOffset, paintContainer); 773 addChildFocusRingRects(rects, additionalOffset, paintContainer);
774 } 774 }
775 775
776 } // namespace blink 776 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/rendering/RenderInline.h ('k') | sky/engine/core/rendering/RenderLayer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698