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

Unified Diff: Source/core/rendering/RenderRuby.cpp

Issue 295513003: add 'slow' prefix to RenderObject's firstChild() / lastChild() methods (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 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/rendering/RenderObject.cpp ('k') | Source/core/rendering/RenderTable.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderRuby.cpp
diff --git a/Source/core/rendering/RenderRuby.cpp b/Source/core/rendering/RenderRuby.cpp
index ece92cdfcf5b6b490336b30516c08e25a26fd961..5383683eebddc1b0b10829609340b314c9b046ba 100644
--- a/Source/core/rendering/RenderRuby.cpp
+++ b/Source/core/rendering/RenderRuby.cpp
@@ -58,27 +58,27 @@ static inline bool isRubyBeforeBlock(const RenderObject* object)
{
return isAnonymousRubyInlineBlock(object)
&& !object->previousSibling()
- && object->firstChild()
- && object->firstChild()->style()->styleType() == BEFORE;
+ && toRenderBlock(object)->firstChild()
+ && toRenderBlock(object)->firstChild()->style()->styleType() == BEFORE;
}
static inline bool isRubyAfterBlock(const RenderObject* object)
{
return isAnonymousRubyInlineBlock(object)
&& !object->nextSibling()
- && object->firstChild()
- && object->firstChild()->style()->styleType() == AFTER;
+ && toRenderBlock(object)->firstChild()
+ && toRenderBlock(object)->firstChild()->style()->styleType() == AFTER;
}
static inline RenderBlock* rubyBeforeBlock(const RenderObject* ruby)
{
- RenderObject* child = ruby->firstChild();
+ RenderObject* child = ruby->slowFirstChild();
return isRubyBeforeBlock(child) ? toRenderBlock(child) : 0;
}
static inline RenderBlock* rubyAfterBlock(const RenderObject* ruby)
{
- RenderObject* child = ruby->lastChild();
+ RenderObject* child = ruby->slowLastChild();
return isRubyAfterBlock(child) ? toRenderBlock(child) : 0;
}
@@ -92,7 +92,7 @@ static RenderBlockFlow* createAnonymousRubyInlineBlock(RenderObject* ruby)
static RenderRubyRun* lastRubyRun(const RenderObject* ruby)
{
- RenderObject* child = ruby->lastChild();
+ RenderObject* child = ruby->slowLastChild();
if (child && !child->isRubyRun())
child = child->previousSibling();
ASSERT(!child || child->isRubyRun() || child->isBeforeContent() || child == rubyBeforeBlock(ruby));
« no previous file with comments | « Source/core/rendering/RenderObject.cpp ('k') | Source/core/rendering/RenderTable.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698