| 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) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
| 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. 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 3726 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3737 if (isInline() || !avoidsFloats() || isFloating()) | 3737 if (isInline() || !avoidsFloats() || isFloating()) |
| 3738 return false; | 3738 return false; |
| 3739 | 3739 |
| 3740 // Only auto width objects can possibly shrink to avoid floats. | 3740 // Only auto width objects can possibly shrink to avoid floats. |
| 3741 return style()->width().isAuto(); | 3741 return style()->width().isAuto(); |
| 3742 } | 3742 } |
| 3743 | 3743 |
| 3744 static bool isReplacedElement(Node* node) | 3744 static bool isReplacedElement(Node* node) |
| 3745 { | 3745 { |
| 3746 // Checkboxes and radioboxes are not isReplaced() nor do they have their own
renderer in which to override avoidFloats(). | 3746 // Checkboxes and radioboxes are not isReplaced() nor do they have their own
renderer in which to override avoidFloats(). |
| 3747 return node && node->isElementNode() && (toElement(node)->isFormControlEleme
nt() || isHTMLImageElement(toElement(node))); | 3747 return node && node->isElementNode() && toElement(node)->isFormControlElemen
t(); |
| 3748 } | 3748 } |
| 3749 | 3749 |
| 3750 bool RenderBox::avoidsFloats() const | 3750 bool RenderBox::avoidsFloats() const |
| 3751 { | 3751 { |
| 3752 return isReplaced() || isReplacedElement(node()) || hasOverflowClip() || isH
R() || isLegend() || isWritingModeRoot() || isFlexItemIncludingDeprecated(); | 3752 return isReplaced() || isReplacedElement(node()) || hasOverflowClip() || isH
R() || isLegend() || isWritingModeRoot() || isFlexItemIncludingDeprecated(); |
| 3753 } | 3753 } |
| 3754 | 3754 |
| 3755 bool RenderBox::hasNonCompositedScrollbars() const | 3755 bool RenderBox::hasNonCompositedScrollbars() const |
| 3756 { | 3756 { |
| 3757 if (RenderLayer* layer = this->layer()) { | 3757 if (RenderLayer* layer = this->layer()) { |
| (...skipping 676 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4434 | 4434 |
| 4435 setLogicalTop(oldLogicalTop); | 4435 setLogicalTop(oldLogicalTop); |
| 4436 setLogicalWidth(oldLogicalWidth); | 4436 setLogicalWidth(oldLogicalWidth); |
| 4437 setMarginLeft(oldMarginLeft); | 4437 setMarginLeft(oldMarginLeft); |
| 4438 setMarginRight(oldMarginRight); | 4438 setMarginRight(oldMarginRight); |
| 4439 | 4439 |
| 4440 return borderBox; | 4440 return borderBox; |
| 4441 } | 4441 } |
| 4442 | 4442 |
| 4443 } // namespace blink | 4443 } // namespace blink |
| OLD | NEW |