OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2002 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2002 Lars Knoll (knoll@kde.org) |
3 * (C) 2002 Dirk Mueller (mueller@kde.org) | 3 * (C) 2002 Dirk Mueller (mueller@kde.org) |
4 * Copyright (C) 2003, 2006, 2008, 2010 Apple Inc. All rights reserved. | 4 * Copyright (C) 2003, 2006, 2008, 2010 Apple Inc. All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License. | 9 * version 2 of the License. |
10 * | 10 * |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 if ((tw.isAuto() || tw.hasPercent()) && !table->isOutOfFlowPositioned())
{ | 188 if ((tw.isAuto() || tw.hasPercent()) && !table->isOutOfFlowPositioned())
{ |
189 LayoutBlock* cb = table->containingBlock(); | 189 LayoutBlock* cb = table->containingBlock(); |
190 while (cb && !cb->isLayoutView() && !cb->isTableCell() | 190 while (cb && !cb->isLayoutView() && !cb->isTableCell() |
191 && cb->style()->width().isAuto() && !cb->isOutOfFlowPositioned()
) | 191 && cb->style()->width().isAuto() && !cb->isOutOfFlowPositioned()
) |
192 cb = cb->containingBlock(); | 192 cb = cb->containingBlock(); |
193 | 193 |
194 table = 0; | 194 table = 0; |
195 if (cb && cb->isTableCell() | 195 if (cb && cb->isTableCell() |
196 && (cb->style()->width().isAuto() || cb->style()->width().hasPer
cent())) { | 196 && (cb->style()->width().isAuto() || cb->style()->width().hasPer
cent())) { |
197 LayoutTableCell* cell = toLayoutTableCell(cb); | 197 LayoutTableCell* cell = toLayoutTableCell(cb); |
198 if (cell->colSpan() > 1 || cell->table()->style()->width().isAut
o()) | 198 if (cell->colSpan() > 1 || cell->table()->isLogicalWidthAuto()) |
199 scale = false; | 199 scale = false; |
200 else | 200 else |
201 table = cell->table(); | 201 table = cell->table(); |
202 } | 202 } |
203 } else { | 203 } else { |
204 table = 0; | 204 table = 0; |
205 } | 205 } |
206 } | 206 } |
207 return scale; | 207 return scale; |
208 } | 208 } |
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
692 int reduce = available * minMaxDiff / logicalWidthBeyondMin; | 692 int reduce = available * minMaxDiff / logicalWidthBeyondMin; |
693 m_layoutStruct[i].computedLogicalWidth += reduce; | 693 m_layoutStruct[i].computedLogicalWidth += reduce; |
694 available -= reduce; | 694 available -= reduce; |
695 logicalWidthBeyondMin -= minMaxDiff; | 695 logicalWidthBeyondMin -= minMaxDiff; |
696 if (available >= 0) | 696 if (available >= 0) |
697 break; | 697 break; |
698 } | 698 } |
699 } | 699 } |
700 } | 700 } |
701 } // namespace blink | 701 } // namespace blink |
OLD | NEW |