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

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

Issue 335963002: Change LayoutState to be stack-allocated (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix push function to match old behavior... Created 6 years, 6 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) 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2011 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 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 void RenderGrid::layoutBlock(bool relayoutChildren) 312 void RenderGrid::layoutBlock(bool relayoutChildren)
313 { 313 {
314 ASSERT(needsLayout()); 314 ASSERT(needsLayout());
315 315
316 if (!relayoutChildren && simplifiedLayout()) 316 if (!relayoutChildren && simplifiedLayout())
317 return; 317 return;
318 318
319 // FIXME: Much of this method is boiler plate that matches RenderBox::layout Block and Render*FlexibleBox::layoutBlock. 319 // FIXME: Much of this method is boiler plate that matches RenderBox::layout Block and Render*FlexibleBox::layoutBlock.
320 // It would be nice to refactor some of the duplicate code. 320 // It would be nice to refactor some of the duplicate code.
321 LayoutRepainter repainter(*this, checkForPaintInvalidationDuringLayout()); 321 LayoutRepainter repainter(*this, checkForPaintInvalidationDuringLayout());
322 LayoutStateMaintainer statePusher(*this, locationOffset()); 322 LayoutState state(*this, locationOffset());
323 323
324 LayoutSize previousSize = size(); 324 LayoutSize previousSize = size();
325 325
326 setLogicalHeight(0); 326 setLogicalHeight(0);
327 updateLogicalWidth(); 327 updateLogicalWidth();
328 328
329 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this); 329 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this);
330 330
331 layoutGridItems(); 331 layoutGridItems();
332 332
(...skipping 916 matching lines...) Expand 10 before | Expand all | Expand 10 after
1249 if (isOutOfFlowPositioned()) 1249 if (isOutOfFlowPositioned())
1250 return "RenderGrid (positioned)"; 1250 return "RenderGrid (positioned)";
1251 if (isAnonymous()) 1251 if (isAnonymous())
1252 return "RenderGrid (generated)"; 1252 return "RenderGrid (generated)";
1253 if (isRelPositioned()) 1253 if (isRelPositioned())
1254 return "RenderGrid (relative positioned)"; 1254 return "RenderGrid (relative positioned)";
1255 return "RenderGrid"; 1255 return "RenderGrid";
1256 } 1256 }
1257 1257
1258 } // namespace WebCore 1258 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698