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

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

Issue 2202493002: NOT FOR REVIEW: Fullscreen WIP (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 1 month 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) 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. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 ASSERT(beforeDescendantContainer); 274 ASSERT(beforeDescendantContainer);
275 275
276 // We really can't go on if what we have found isn't anonymous. We're not 276 // We really can't go on if what we have found isn't anonymous. We're not
277 // supposed to use some random non-anonymous object and put the child there. 277 // supposed to use some random non-anonymous object and put the child there.
278 // That's a recipe for security issues. 278 // That's a recipe for security issues.
279 RELEASE_ASSERT(beforeDescendantContainer->isAnonymous()); 279 RELEASE_ASSERT(beforeDescendantContainer->isAnonymous());
280 280
281 // If the requested insertion point is not one of our children, then this is 281 // If the requested insertion point is not one of our children, then this is
282 // because there is an anonymous container within this object that contains 282 // because there is an anonymous container within this object that contains
283 // the beforeDescendant. 283 // the beforeDescendant.
284 if (beforeDescendantContainer->isAnonymousBlock() 284 if (beforeDescendantContainer->isAnonymousBlock()) {
285 // Full screen layoutObjects and full screen placeholders act as anonymous
286 // blocks, not tables:
287 || beforeDescendantContainer->isLayoutFullScreen() ||
288 beforeDescendantContainer->isLayoutFullScreenPlaceholder()) {
289 // Insert the child into the anonymous block box instead of here. 285 // Insert the child into the anonymous block box instead of here.
290 if (newChild->isInline() || newChild->isFloatingOrOutOfFlowPositioned() || 286 if (newChild->isInline() || newChild->isFloatingOrOutOfFlowPositioned() ||
291 beforeDescendant->parent()->slowFirstChild() != beforeDescendant) 287 beforeDescendant->parent()->slowFirstChild() != beforeDescendant)
292 beforeDescendant->parent()->addChild(newChild, beforeDescendant); 288 beforeDescendant->parent()->addChild(newChild, beforeDescendant);
293 else 289 else
294 addChild(newChild, beforeDescendant->parent()); 290 addChild(newChild, beforeDescendant->parent());
295 return; 291 return;
296 } 292 }
297 293
298 ASSERT(beforeDescendantContainer->isTable()); 294 ASSERT(beforeDescendantContainer->isTable());
(...skipping 1907 matching lines...) Expand 10 before | Expand all | Expand 10 after
2206 } 2202 }
2207 2203
2208 return availableHeight; 2204 return availableHeight;
2209 } 2205 }
2210 2206
2211 bool LayoutBlock::hasDefiniteLogicalHeight() const { 2207 bool LayoutBlock::hasDefiniteLogicalHeight() const {
2212 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); 2208 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1);
2213 } 2209 }
2214 2210
2215 } // namespace blink 2211 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/BUILD.gn ('k') | third_party/WebKit/Source/core/layout/LayoutBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698