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

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

Issue 397733004: Allow assertions to be enabled in Blink Release builds. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased. 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
« no previous file with comments | « Source/core/rendering/RenderLineBoxList.cpp ('k') | Source/core/rendering/RenderObject.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) 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 largestHeight = height; 124 largestHeight = height;
125 indexWithLargestHeight = i; 125 indexWithLargestHeight = i;
126 } 126 }
127 previousOffset = run.breakOffset(); 127 previousOffset = run.breakOffset();
128 } 128 }
129 return indexWithLargestHeight; 129 return indexWithLargestHeight;
130 } 130 }
131 131
132 void RenderMultiColumnSet::distributeImplicitBreaks() 132 void RenderMultiColumnSet::distributeImplicitBreaks()
133 { 133 {
134 #ifndef NDEBUG 134 #if ENABLE(ASSERT)
135 // There should be no implicit breaks assumed at this point. 135 // There should be no implicit breaks assumed at this point.
136 for (unsigned i = 0; i < m_contentRuns.size(); i++) 136 for (unsigned i = 0; i < m_contentRuns.size(); i++)
137 ASSERT(!m_contentRuns[i].assumedImplicitBreaks()); 137 ASSERT(!m_contentRuns[i].assumedImplicitBreaks());
138 #endif // NDEBUG 138 #endif // ENABLE(ASSERT)
139 139
140 // Insert a final content run to encompass all content. This will include ov erflow if this is 140 // Insert a final content run to encompass all content. This will include ov erflow if this is
141 // the last set. 141 // the last set.
142 addContentRun(logicalBottomInFlowThread()); 142 addContentRun(logicalBottomInFlowThread());
143 unsigned columnCount = m_contentRuns.size(); 143 unsigned columnCount = m_contentRuns.size();
144 144
145 // If there is room for more breaks (to reach the used value of column-count ), imagine that we 145 // If there is room for more breaks (to reach the used value of column-count ), imagine that we
146 // insert implicit breaks at suitable locations. At any given time, the cont ent run with the 146 // insert implicit breaks at suitable locations. At any given time, the cont ent run with the
147 // currently tallest columns will get another implicit break "inserted", whi ch will increase its 147 // currently tallest columns will get another implicit break "inserted", whi ch will increase its
148 // column count by one and shrink its columns' height. Repeat until we have the desired total 148 // column count by one and shrink its columns' height. Repeat until we have the desired total
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
687 687
688 void RenderMultiColumnSet::detachRegion() 688 void RenderMultiColumnSet::detachRegion()
689 { 689 {
690 if (m_flowThread) { 690 if (m_flowThread) {
691 m_flowThread->removeRegionFromThread(this); 691 m_flowThread->removeRegionFromThread(this);
692 m_flowThread = 0; 692 m_flowThread = 0;
693 } 693 }
694 } 694 }
695 695
696 } 696 }
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderLineBoxList.cpp ('k') | Source/core/rendering/RenderObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698