| 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 1271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1282 // FIXME: This calculation is not patched for block-flow yet. | 1282 // FIXME: This calculation is not patched for block-flow yet. |
| 1283 // https://bugs.webkit.org/show_bug.cgi?id=46500 | 1283 // https://bugs.webkit.org/show_bug.cgi?id=46500 |
| 1284 computePositionedLogicalWidth(computedValues); | 1284 computePositionedLogicalWidth(computedValues); |
| 1285 return; | 1285 return; |
| 1286 } | 1286 } |
| 1287 | 1287 |
| 1288 // If layout is limited to a subtree, the subtree root's logical width does
not change. | 1288 // If layout is limited to a subtree, the subtree root's logical width does
not change. |
| 1289 if (node() && view()->frameView() && view()->frameView()->layoutRoot(true) =
= this) | 1289 if (node() && view()->frameView() && view()->frameView()->layoutRoot(true) =
= this) |
| 1290 return; | 1290 return; |
| 1291 | 1291 |
| 1292 // The parent box is flexing us, so it has increased or decreased our | 1292 if (hasOverrideWidth()) { |
| 1293 // width. Use the width from the style context. | |
| 1294 // FIXME: Account for block-flow in flexible boxes. | |
| 1295 // https://bugs.webkit.org/show_bug.cgi?id=46418 | |
| 1296 if (hasOverrideWidth() && parent()->isFlexibleBox()) { | |
| 1297 computedValues.m_extent = overrideLogicalContentWidth() + borderAndPaddi
ngLogicalWidth(); | 1293 computedValues.m_extent = overrideLogicalContentWidth() + borderAndPaddi
ngLogicalWidth(); |
| 1298 return; | 1294 return; |
| 1299 } | 1295 } |
| 1300 | 1296 |
| 1301 bool treatAsReplaced = shouldComputeSizeAsReplaced(); | 1297 bool treatAsReplaced = shouldComputeSizeAsReplaced(); |
| 1302 | 1298 |
| 1303 RenderStyle* styleToUse = style(); | 1299 RenderStyle* styleToUse = style(); |
| 1304 Length logicalWidthLength = treatAsReplaced ? Length(computeReplacedLogicalW
idth(), Fixed) : styleToUse->logicalWidth(); | 1300 Length logicalWidthLength = treatAsReplaced ? Length(computeReplacedLogicalW
idth(), Fixed) : styleToUse->logicalWidth(); |
| 1305 | 1301 |
| 1306 RenderBlock* cb = containingBlock(); | 1302 RenderBlock* cb = containingBlock(); |
| (...skipping 1771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3078 | 3074 |
| 3079 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) | 3075 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) |
| 3080 { | 3076 { |
| 3081 backgroundColor = style.colorIncludingFallback(CSSPropertyBackgroundColor); | 3077 backgroundColor = style.colorIncludingFallback(CSSPropertyBackgroundColor); |
| 3082 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); | 3078 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); |
| 3083 ASSERT(hasBackground == style.hasBackground()); | 3079 ASSERT(hasBackground == style.hasBackground()); |
| 3084 hasBorder = style.hasBorder(); | 3080 hasBorder = style.hasBorder(); |
| 3085 } | 3081 } |
| 3086 | 3082 |
| 3087 } // namespace blink | 3083 } // namespace blink |
| OLD | NEW |