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

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

Issue 834653003: [Slimming paint] [New Multicolumn] Repaint column rules when they change. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Make the test useful. Created 5 years, 11 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
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 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 } 209 }
210 } 210 }
211 211
212 if (needsRelayout) 212 if (needsRelayout)
213 setChildNeedsLayout(MarkOnlyThis); 213 setChildNeedsLayout(MarkOnlyThis);
214 214
215 m_inBalancingPass = needsRelayout; 215 m_inBalancingPass = needsRelayout;
216 return needsRelayout; 216 return needsRelayout;
217 } 217 }
218 218
219 void RenderMultiColumnFlowThread::columnRuleStyleDidChange()
220 {
221 for (RenderMultiColumnSet* columnSet = firstMultiColumnSet(); columnSet; col umnSet = columnSet->nextSiblingMultiColumnSet())
222 columnSet->setShouldDoFullPaintInvalidation(PaintInvalidationStyleChange );
223 }
224
219 void RenderMultiColumnFlowThread::calculateColumnCountAndWidth(LayoutUnit& width , unsigned& count) const 225 void RenderMultiColumnFlowThread::calculateColumnCountAndWidth(LayoutUnit& width , unsigned& count) const
220 { 226 {
221 RenderBlock* columnBlock = multiColumnBlockFlow(); 227 RenderBlock* columnBlock = multiColumnBlockFlow();
222 const RenderStyle* columnStyle = columnBlock->style(); 228 const RenderStyle* columnStyle = columnBlock->style();
223 LayoutUnit availableWidth = columnBlock->contentLogicalWidth(); 229 LayoutUnit availableWidth = columnBlock->contentLogicalWidth();
224 LayoutUnit columnGap = columnBlock->columnGap(); 230 LayoutUnit columnGap = columnBlock->columnGap();
225 LayoutUnit computedColumnWidth = max<LayoutUnit>(1, LayoutUnit(columnStyle-> columnWidth())); 231 LayoutUnit computedColumnWidth = max<LayoutUnit>(1, LayoutUnit(columnStyle-> columnWidth()));
226 unsigned computedColumnCount = max<int>(1, columnStyle->columnCount()); 232 unsigned computedColumnCount = max<int>(1, columnStyle->columnCount());
227 233
228 ASSERT(!columnStyle->hasAutoColumnCount() || !columnStyle->hasAutoColumnWidt h()); 234 ASSERT(!columnStyle->hasAutoColumnCount() || !columnStyle->hasAutoColumnWidt h());
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
434 } 440 }
435 441
436 bool RenderMultiColumnFlowThread::isPageLogicalHeightKnown() const 442 bool RenderMultiColumnFlowThread::isPageLogicalHeightKnown() const
437 { 443 {
438 if (RenderMultiColumnSet* columnSet = lastMultiColumnSet()) 444 if (RenderMultiColumnSet* columnSet = lastMultiColumnSet())
439 return columnSet->pageLogicalHeight(); 445 return columnSet->pageLogicalHeight();
440 return false; 446 return false;
441 } 447 }
442 448
443 } 449 }
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderMultiColumnFlowThread.h ('k') | Source/core/rendering/style/RenderStyle.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698