OLD | NEW |
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 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
511 PaintLayer* layer = enclosingLayer(); | 511 PaintLayer* layer = enclosingLayer(); |
512 if (!needsLayout() && layer->hasCompositedLayerMapping() && | 512 if (!needsLayout() && layer->hasCompositedLayerMapping() && |
513 !layer->visualRect().contains(visualOverflowRect())) | 513 !layer->visualRect().contains(visualOverflowRect())) |
514 layer->setNeedsCompositingInputsUpdate(); | 514 layer->setNeedsCompositingInputsUpdate(); |
515 } | 515 } |
516 | 516 |
517 void LayoutBlock::addOverflowFromBlockChildren() { | 517 void LayoutBlock::addOverflowFromBlockChildren() { |
518 for (LayoutBox* child = firstChildBox(); child; | 518 for (LayoutBox* child = firstChildBox(); child; |
519 child = child->nextSiblingBox()) { | 519 child = child->nextSiblingBox()) { |
520 if (!child->isFloatingOrOutOfFlowPositioned() && !child->isColumnSpanAll()) | 520 if (!child->isFloatingOrOutOfFlowPositioned() && !child->isColumnSpanAll()) |
521 addOverflowFromChild(child); | 521 addOverflowFromChild(*child); |
522 } | 522 } |
523 } | 523 } |
524 | 524 |
525 void LayoutBlock::addOverflowFromPositionedObjects() { | 525 void LayoutBlock::addOverflowFromPositionedObjects() { |
526 TrackedLayoutBoxListHashSet* positionedDescendants = positionedObjects(); | 526 TrackedLayoutBoxListHashSet* positionedDescendants = positionedObjects(); |
527 if (!positionedDescendants) | 527 if (!positionedDescendants) |
528 return; | 528 return; |
529 | 529 |
530 for (auto* positionedObject : *positionedDescendants) { | 530 for (auto* positionedObject : *positionedDescendants) { |
531 // Fixed positioned elements don't contribute to layout overflow, since they | 531 // Fixed positioned elements don't contribute to layout overflow, since they |
532 // don't scroll with the content. | 532 // don't scroll with the content. |
533 if (positionedObject->style()->position() != EPosition::kFixed) | 533 if (positionedObject->style()->position() != EPosition::kFixed) |
534 addOverflowFromChild(positionedObject, | 534 addOverflowFromChild(*positionedObject, |
535 toLayoutSize(positionedObject->location())); | 535 toLayoutSize(positionedObject->location())); |
536 } | 536 } |
537 } | 537 } |
538 | 538 |
539 void LayoutBlock::addVisualOverflowFromTheme() { | 539 void LayoutBlock::addVisualOverflowFromTheme() { |
540 if (!style()->hasAppearance()) | 540 if (!style()->hasAppearance()) |
541 return; | 541 return; |
542 | 542 |
543 IntRect inflatedRect = pixelSnappedBorderBoxRect(); | 543 IntRect inflatedRect = pixelSnappedBorderBoxRect(); |
544 LayoutTheme::theme().addVisualOverflow(*this, inflatedRect); | 544 LayoutTheme::theme().addVisualOverflow(*this, inflatedRect); |
(...skipping 1621 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2166 } | 2166 } |
2167 | 2167 |
2168 return availableHeight; | 2168 return availableHeight; |
2169 } | 2169 } |
2170 | 2170 |
2171 bool LayoutBlock::hasDefiniteLogicalHeight() const { | 2171 bool LayoutBlock::hasDefiniteLogicalHeight() const { |
2172 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); | 2172 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); |
2173 } | 2173 } |
2174 | 2174 |
2175 } // namespace blink | 2175 } // namespace blink |
OLD | NEW |