| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Copyright (C) 1997 Martin Jones (mjones@kde.org) | 2  * Copyright (C) 1997 Martin Jones (mjones@kde.org) | 
| 3  *           (C) 1997 Torben Weis (weis@kde.org) | 3  *           (C) 1997 Torben Weis (weis@kde.org) | 
| 4  *           (C) 1998 Waldo Bastian (bastian@kde.org) | 4  *           (C) 1998 Waldo Bastian (bastian@kde.org) | 
| 5  *           (C) 1999 Lars Knoll (knoll@kde.org) | 5  *           (C) 1999 Lars Knoll (knoll@kde.org) | 
| 6  *           (C) 1999 Antti Koivisto (koivisto@kde.org) | 6  *           (C) 1999 Antti Koivisto (koivisto@kde.org) | 
| 7  * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r
      ights reserved. | 7  * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r
      ights reserved. | 
| 8  * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 8  * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 
| 9  * | 9  * | 
| 10  * This library is free software; you can redistribute it and/or | 10  * This library is free software; you can redistribute it and/or | 
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 231 | 231 | 
| 232     LayoutUnit availableLogicalWidth = containingBlockLogicalWidthForContent(); | 232     LayoutUnit availableLogicalWidth = containingBlockLogicalWidthForContent(); | 
| 233     bool hasPerpendicularContainingBlock = cb->style()->isHorizontalWritingMode(
      ) != style()->isHorizontalWritingMode(); | 233     bool hasPerpendicularContainingBlock = cb->style()->isHorizontalWritingMode(
      ) != style()->isHorizontalWritingMode(); | 
| 234     LayoutUnit containerWidthInInlineDirection = hasPerpendicularContainingBlock
       ? perpendicularContainingBlockLogicalHeight() : availableLogicalWidth; | 234     LayoutUnit containerWidthInInlineDirection = hasPerpendicularContainingBlock
       ? perpendicularContainingBlockLogicalHeight() : availableLogicalWidth; | 
| 235 | 235 | 
| 236     LengthType logicalWidthType = style()->logicalWidth().type(); | 236     LengthType logicalWidthType = style()->logicalWidth().type(); | 
| 237     if (logicalWidthType > Relative && style()->logicalWidth().isPositive()) { | 237     if (logicalWidthType > Relative && style()->logicalWidth().isPositive()) { | 
| 238         // Percent or fixed table | 238         // Percent or fixed table | 
| 239         // HTML tables size as though CSS width includes border/padding, CSS tab
      les do not. | 239         // HTML tables size as though CSS width includes border/padding, CSS tab
      les do not. | 
| 240         LayoutUnit borders = 0; | 240         LayoutUnit borders = 0; | 
| 241         if (!node() || !node()->hasTagName(tableTag)) { | 241         if (logicalWidthType != Percent && (!node() || !node()->hasTagName(table
      Tag))) { | 
| 242             bool collapsing = collapseBorders(); | 242             bool collapsing = collapseBorders(); | 
| 243             LayoutUnit borderAndPaddingBefore = borderBefore() + (collapsing ? 0
       : paddingBefore()); | 243             LayoutUnit borderAndPaddingBefore = borderBefore() + (collapsing ? 0
       : paddingBefore()); | 
| 244             LayoutUnit borderAndPaddingAfter = borderAfter() + (collapsing ? 0 :
       paddingAfter()); | 244             LayoutUnit borderAndPaddingAfter = borderAfter() + (collapsing ? 0 :
       paddingAfter()); | 
| 245             borders = borderAndPaddingBefore + borderAndPaddingAfter; | 245             borders = borderAndPaddingBefore + borderAndPaddingAfter; | 
| 246         } | 246         } | 
| 247         setLogicalWidth(style()->logicalWidth().calcMinValue(containerWidthInInl
      ineDirection) + borders); | 247         setLogicalWidth(style()->logicalWidth().calcMinValue(containerWidthInInl
      ineDirection) + borders); | 
| 248         setLogicalWidth(max(minPreferredLogicalWidth(), logicalWidth())); | 248         setLogicalWidth(max(minPreferredLogicalWidth(), logicalWidth())); | 
| 249     } else { | 249     } else { | 
| 250         // Subtract out any fixed margins from our available width for auto widt
      h tables. | 250         // Subtract out any fixed margins from our available width for auto widt
      h tables. | 
| 251         LayoutUnit marginTotal = 0; | 251         LayoutUnit marginTotal = 0; | 
| (...skipping 990 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1242     if (visibleToHitTesting() && (action == HitTestBlockBackground || action == 
      HitTestChildBlockBackground) && boundsRect.intersects(result.rectForPoint(pointI
      nContainer))) { | 1242     if (visibleToHitTesting() && (action == HitTestBlockBackground || action == 
      HitTestChildBlockBackground) && boundsRect.intersects(result.rectForPoint(pointI
      nContainer))) { | 
| 1243         updateHitTestResult(result, flipForWritingMode(pointInContainer - toLayo
      utSize(adjustedLocation))); | 1243         updateHitTestResult(result, flipForWritingMode(pointInContainer - toLayo
      utSize(adjustedLocation))); | 
| 1244         if (!result.addNodeToRectBasedTestResult(node(), pointInContainer, bound
      sRect)) | 1244         if (!result.addNodeToRectBasedTestResult(node(), pointInContainer, bound
      sRect)) | 
| 1245             return true; | 1245             return true; | 
| 1246     } | 1246     } | 
| 1247 | 1247 | 
| 1248     return false; | 1248     return false; | 
| 1249 } | 1249 } | 
| 1250 | 1250 | 
| 1251 } | 1251 } | 
| OLD | NEW | 
|---|