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

Side by Side Diff: Source/core/rendering/RenderBlock.cpp

Issue 397733004: Allow assertions to be enabled in Blink Release builds. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fixed config.gni. Minor cleanups. 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 unified diff | Download patch | Annotate | Revision Log
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 * (C) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 994 matching lines...) Expand 10 before | Expand all | Expand 10 after
1005 if (!inlineRunStart) 1005 if (!inlineRunStart)
1006 break; 1006 break;
1007 1007
1008 child = inlineRunEnd->nextSibling(); 1008 child = inlineRunEnd->nextSibling();
1009 1009
1010 RenderBlock* block = createAnonymousBlock(); 1010 RenderBlock* block = createAnonymousBlock();
1011 children()->insertChildNode(this, block, inlineRunStart); 1011 children()->insertChildNode(this, block, inlineRunStart);
1012 moveChildrenTo(block, inlineRunStart, child); 1012 moveChildrenTo(block, inlineRunStart, child);
1013 } 1013 }
1014 1014
1015 #ifndef NDEBUG 1015 #if ENABLE(ASSERT)
1016 for (RenderObject *c = firstChild(); c; c = c->nextSibling()) 1016 for (RenderObject *c = firstChild(); c; c = c->nextSibling())
1017 ASSERT(!c->isInline()); 1017 ASSERT(!c->isInline());
1018 #endif 1018 #endif
1019 1019
1020 paintInvalidationForWholeRenderer(); 1020 paintInvalidationForWholeRenderer();
1021 } 1021 }
1022 1022
1023 void RenderBlock::removeLeftoverAnonymousBlock(RenderBlock* child) 1023 void RenderBlock::removeLeftoverAnonymousBlock(RenderBlock* child)
1024 { 1024 {
1025 ASSERT(child->isAnonymousBlock()); 1025 ASSERT(child->isAnonymousBlock());
(...skipping 3883 matching lines...) Expand 10 before | Expand all | Expand 10 after
4909 4909
4910 LayoutUnit oldClientAfterEdge = hasRenderOverflow() ? m_overflow->layoutClie ntAfterEdge() : clientLogicalBottom(); 4910 LayoutUnit oldClientAfterEdge = hasRenderOverflow() ? m_overflow->layoutClie ntAfterEdge() : clientLogicalBottom();
4911 computeOverflow(oldClientAfterEdge, true); 4911 computeOverflow(oldClientAfterEdge, true);
4912 4912
4913 if (hasOverflowClip()) 4913 if (hasOverflowClip())
4914 layer()->scrollableArea()->updateAfterOverflowRecalc(); 4914 layer()->scrollableArea()->updateAfterOverflowRecalc();
4915 4915
4916 return !hasOverflowClip(); 4916 return !hasOverflowClip();
4917 } 4917 }
4918 4918
4919 #ifndef NDEBUG 4919 #if ENABLE(ASSERT)
4920 void RenderBlock::checkPositionedObjectsNeedLayout() 4920 void RenderBlock::checkPositionedObjectsNeedLayout()
4921 { 4921 {
4922 if (!gPositionedDescendantsMap) 4922 if (!gPositionedDescendantsMap)
4923 return; 4923 return;
4924 4924
4925 if (TrackedRendererListHashSet* positionedDescendantSet = positionedObjects( )) { 4925 if (TrackedRendererListHashSet* positionedDescendantSet = positionedObjects( )) {
4926 TrackedRendererListHashSet::const_iterator end = positionedDescendantSet ->end(); 4926 TrackedRendererListHashSet::const_iterator end = positionedDescendantSet ->end();
4927 for (TrackedRendererListHashSet::const_iterator it = positionedDescendan tSet->begin(); it != end; ++it) { 4927 for (TrackedRendererListHashSet::const_iterator it = positionedDescendan tSet->begin(); it != end; ++it) {
4928 RenderBox* currBox = *it; 4928 RenderBox* currBox = *it;
4929 ASSERT(!currBox->needsLayout()); 4929 ASSERT(!currBox->needsLayout());
4930 } 4930 }
4931 } 4931 }
4932 } 4932 }
4933 4933
4934 #endif
4935
4936 #ifndef NDEBUG
4937
4934 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const 4938 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const
4935 { 4939 {
4936 showRenderObject(); 4940 showRenderObject();
4937 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) 4941 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box())
4938 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); 4942 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1);
4939 } 4943 }
4940 4944
4941 #endif 4945 #endif
4942 4946
4943 } // namespace WebCore 4947 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698