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 2819 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2830 case FitContent: | 2830 case FitContent: |
2831 case FillAvailable: | 2831 case FillAvailable: |
2832 return adjustContentBoxLogicalHeightForBoxSizing(computeIntrinsicLog
icalContentHeightUsing(logicalHeight, intrinsicLogicalHeight(), borderAndPadding
Height())); | 2832 return adjustContentBoxLogicalHeightForBoxSizing(computeIntrinsicLog
icalContentHeightUsing(logicalHeight, intrinsicLogicalHeight(), borderAndPadding
Height())); |
2833 default: | 2833 default: |
2834 return intrinsicLogicalHeight(); | 2834 return intrinsicLogicalHeight(); |
2835 } | 2835 } |
2836 } | 2836 } |
2837 | 2837 |
2838 LayoutUnit RenderBox::availableLogicalHeight(AvailableLogicalHeightType heightTy
pe) const | 2838 LayoutUnit RenderBox::availableLogicalHeight(AvailableLogicalHeightType heightTy
pe) const |
2839 { | 2839 { |
2840 return constrainLogicalHeightByMinMax(availableLogicalHeightUsing(style()->l
ogicalHeight(), heightType), -1); | 2840 // http://www.w3.org/TR/CSS2/visudet.html#propdef-height - We are interested
in the content height. |
| 2841 return constrainContentBoxLogicalHeightByMinMax(availableLogicalHeightUsing(
style()->logicalHeight(), heightType), -1); |
2841 } | 2842 } |
2842 | 2843 |
2843 LayoutUnit RenderBox::availableLogicalHeightUsing(const Length& h, AvailableLogi
calHeightType heightType) const | 2844 LayoutUnit RenderBox::availableLogicalHeightUsing(const Length& h, AvailableLogi
calHeightType heightType) const |
2844 { | 2845 { |
2845 if (isRenderView()) | 2846 if (isRenderView()) |
2846 return isHorizontalWritingMode() ? toRenderView(this)->frameView()->visi
bleHeight() : toRenderView(this)->frameView()->visibleWidth(); | 2847 return isHorizontalWritingMode() ? toRenderView(this)->frameView()->visi
bleHeight() : toRenderView(this)->frameView()->visibleWidth(); |
2847 | 2848 |
2848 // We need to stop here, since we don't want to increase the height of the t
able | 2849 // We need to stop here, since we don't want to increase the height of the t
able |
2849 // artificially. We're going to rely on this cell getting expanded to some
new | 2850 // artificially. We're going to rely on this cell getting expanded to some
new |
2850 // height, and then when we lay out again we'll use the calculation below. | 2851 // height, and then when we lay out again we'll use the calculation below. |
(...skipping 1816 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4667 | 4668 |
4668 // We need the old border box size only when the box has background or b
ox decorations. | 4669 // We need the old border box size only when the box has background or b
ox decorations. |
4669 if (!style()->hasBackground() && !style()->hasBoxDecorations()) | 4670 if (!style()->hasBackground() && !style()->hasBoxDecorations()) |
4670 return; | 4671 return; |
4671 } | 4672 } |
4672 | 4673 |
4673 ensureRareData().m_previousBorderBoxSize = size(); | 4674 ensureRareData().m_previousBorderBoxSize = size(); |
4674 } | 4675 } |
4675 | 4676 |
4676 } // namespace WebCore | 4677 } // namespace WebCore |
OLD | NEW |