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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutMultiColumnSet.cpp

Issue 1898293003: Make MultiColumnFragmentainerGroup::m_columnSet const. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 295 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 if (m_oldLogicalTop != logicalTop() && multiColumnFlowThread()->enclosingFra gmentationContext()) { 306 if (m_oldLogicalTop != logicalTop() && multiColumnFlowThread()->enclosingFra gmentationContext()) {
307 // Preceding spanners or column sets have been moved or resized. This me ans that the 307 // Preceding spanners or column sets have been moved or resized. This me ans that the
308 // fragmentainer groups that we have inserted need to be re-inserted. Re start column 308 // fragmentainer groups that we have inserted need to be re-inserted. Re start column
309 // balancing. 309 // balancing.
310 resetColumnHeight(); 310 resetColumnHeight();
311 return true; 311 return true;
312 } 312 }
313 313
314 bool changed = false; 314 bool changed = false;
315 for (auto& group : m_fragmentainerGroups) 315 for (auto& group : m_fragmentainerGroups)
316 changed = group.recalculateColumnHeight() || changed; 316 changed = group.recalculateColumnHeight(*this) || changed;
317 m_initialHeightCalculated = true; 317 m_initialHeightCalculated = true;
318 return changed; 318 return changed;
319 } 319 }
320 320
321 void LayoutMultiColumnSet::resetColumnHeight() 321 void LayoutMultiColumnSet::resetColumnHeight()
322 { 322 {
323 m_fragmentainerGroups.deleteExtraGroups(); 323 m_fragmentainerGroups.deleteExtraGroups();
324 m_fragmentainerGroups.first().resetColumnHeight(); 324 m_fragmentainerGroups.first().resetColumnHeight();
325 m_tallestUnbreakableLogicalHeight = LayoutUnit(); 325 m_tallestUnbreakableLogicalHeight = LayoutUnit();
326 m_initialHeightCalculated = false; 326 m_initialHeightCalculated = false;
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 467
468 LayoutRect LayoutMultiColumnSet::flowThreadPortionRect() const 468 LayoutRect LayoutMultiColumnSet::flowThreadPortionRect() const
469 { 469 {
470 LayoutRect portionRect(LayoutUnit(), logicalTopInFlowThread(), pageLogicalWi dth(), logicalHeightInFlowThread()); 470 LayoutRect portionRect(LayoutUnit(), logicalTopInFlowThread(), pageLogicalWi dth(), logicalHeightInFlowThread());
471 if (!isHorizontalWritingMode()) 471 if (!isHorizontalWritingMode())
472 return portionRect.transposedRect(); 472 return portionRect.transposedRect();
473 return portionRect; 473 return portionRect;
474 } 474 }
475 475
476 } // namespace blink 476 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698