| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. | 2 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above | 8 * 1. Redistributions of source code must retain the above |
| 9 * copyright notice, this list of conditions and the following | 9 * copyright notice, this list of conditions and the following |
| 10 * disclaimer. | 10 * disclaimer. |
| (...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 275 case ShapeValue::Shape: | 275 case ShapeValue::Shape: |
| 276 return shapeValue->shape(); | 276 return shapeValue->shape(); |
| 277 case ShapeValue::Image: | 277 case ShapeValue::Image: |
| 278 return shapeValue->isImageValid() && checkShapeImageOrigin(box.document(
), *(shapeValue->image())); | 278 return shapeValue->isImageValid() && checkShapeImageOrigin(box.document(
), *(shapeValue->image())); |
| 279 case ShapeValue::Box: | 279 case ShapeValue::Box: |
| 280 return true; | 280 return true; |
| 281 } | 281 } |
| 282 | 282 |
| 283 return false; | 283 return false; |
| 284 } | 284 } |
| 285 ShapeOutsideDeltas ShapeOutsideInfo::computeDeltasForContainingBlockLine(const L
ayoutBlockFlow& containingBlock, const FloatingObject& floatingObject, LayoutUni
t lineTop, LayoutUnit lineHeight) | 285 |
| 286 ShapeOutsideDeltas ShapeOutsideInfo::computeDeltasForContainingBlockLine(const L
ineLayoutBlockFlow& containingBlock, const FloatingObject& floatingObject, Layou
tUnit lineTop, LayoutUnit lineHeight) |
| 286 { | 287 { |
| 287 ASSERT(lineHeight >= 0); | 288 ASSERT(lineHeight >= 0); |
| 288 | 289 |
| 289 LayoutUnit borderBoxTop = containingBlock.logicalTopForFloat(floatingObject)
+ containingBlock.marginBeforeForChild(m_layoutBox); | 290 LayoutUnit borderBoxTop = containingBlock.logicalTopForFloat(floatingObject)
+ containingBlock.marginBeforeForChild(m_layoutBox); |
| 290 LayoutUnit borderBoxLineTop = lineTop - borderBoxTop; | 291 LayoutUnit borderBoxLineTop = lineTop - borderBoxTop; |
| 291 | 292 |
| 292 if (isShapeDirty() || !m_shapeOutsideDeltas.isForLine(borderBoxLineTop, line
Height)) { | 293 if (isShapeDirty() || !m_shapeOutsideDeltas.isForLine(borderBoxLineTop, line
Height)) { |
| 293 LayoutUnit referenceBoxLineTop = borderBoxLineTop - logicalTopOffset(); | 294 LayoutUnit referenceBoxLineTop = borderBoxLineTop - logicalTopOffset(); |
| 294 LayoutUnit floatMarginBoxWidth = std::max(containingBlock.logicalWidthFo
rFloat(floatingObject), LayoutUnit()); | 295 LayoutUnit floatMarginBoxWidth = std::max(containingBlock.logicalWidthFo
rFloat(floatingObject), LayoutUnit()); |
| 295 | 296 |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 347 } | 348 } |
| 348 | 349 |
| 349 FloatSize ShapeOutsideInfo::shapeToLayoutObjectSize(FloatSize size) const | 350 FloatSize ShapeOutsideInfo::shapeToLayoutObjectSize(FloatSize size) const |
| 350 { | 351 { |
| 351 if (!m_layoutBox.style()->isHorizontalWritingMode()) | 352 if (!m_layoutBox.style()->isHorizontalWritingMode()) |
| 352 return size.transposedSize(); | 353 return size.transposedSize(); |
| 353 return size; | 354 return size; |
| 354 } | 355 } |
| 355 | 356 |
| 356 } // namespace blink | 357 } // namespace blink |
| OLD | NEW |