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 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights
reserved. | 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 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, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 1110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1121 if (isRelPositioned()) | 1121 if (isRelPositioned()) |
1122 offset += offsetForInFlowPosition(); | 1122 offset += offsetForInFlowPosition(); |
1123 | 1123 |
1124 offset += container->columnOffset(point); | 1124 offset += container->columnOffset(point); |
1125 | 1125 |
1126 if (container->hasOverflowClip()) | 1126 if (container->hasOverflowClip()) |
1127 offset -= toRenderBox(container)->scrolledContentOffset(); | 1127 offset -= toRenderBox(container)->scrolledContentOffset(); |
1128 | 1128 |
1129 if (offsetDependsOnPoint) { | 1129 if (offsetDependsOnPoint) { |
1130 *offsetDependsOnPoint = container->hasColumns() | 1130 *offsetDependsOnPoint = container->hasColumns() |
1131 || (container->isBox() && container->style()->isFlippedBlocksWriting
Mode()) | 1131 || (container->isBox() && container->style()->slowIsFlippedBlocksWri
tingMode()) |
1132 || container->isRenderFlowThread(); | 1132 || container->isRenderFlowThread(); |
1133 } | 1133 } |
1134 | 1134 |
1135 return offset; | 1135 return offset; |
1136 } | 1136 } |
1137 | 1137 |
1138 void RenderInline::mapLocalToContainer(const RenderLayerModelObject* paintInvali
dationContainer, TransformState& transformState, MapCoordinatesFlags mode, bool*
wasFixed, const PaintInvalidationState* paintInvalidationState) const | 1138 void RenderInline::mapLocalToContainer(const RenderLayerModelObject* paintInvali
dationContainer, TransformState& transformState, MapCoordinatesFlags mode, bool*
wasFixed, const PaintInvalidationState* paintInvalidationState) const |
1139 { | 1139 { |
1140 if (paintInvalidationContainer == this) | 1140 if (paintInvalidationContainer == this) |
1141 return; | 1141 return; |
1142 | 1142 |
1143 if (paintInvalidationState && paintInvalidationState->canMapToContainer(pain
tInvalidationContainer)) { | 1143 if (paintInvalidationState && paintInvalidationState->canMapToContainer(pain
tInvalidationContainer)) { |
1144 LayoutSize offset = paintInvalidationState->paintOffset(); | 1144 LayoutSize offset = paintInvalidationState->paintOffset(); |
1145 if (style()->hasInFlowPosition() && layer()) | 1145 if (style()->hasInFlowPosition() && layer()) |
1146 offset += layer()->offsetForInFlowPosition(); | 1146 offset += layer()->offsetForInFlowPosition(); |
1147 transformState.move(offset); | 1147 transformState.move(offset); |
1148 return; | 1148 return; |
1149 } | 1149 } |
1150 | 1150 |
1151 bool containerSkipped; | 1151 bool containerSkipped; |
1152 RenderObject* o = container(paintInvalidationContainer, &containerSkipped); | 1152 RenderObject* o = container(paintInvalidationContainer, &containerSkipped); |
1153 if (!o) | 1153 if (!o) |
1154 return; | 1154 return; |
1155 | 1155 |
1156 if (mode & ApplyContainerFlip && o->isBox()) { | 1156 if (mode & ApplyContainerFlip && o->isBox()) { |
1157 if (o->style()->isFlippedBlocksWritingMode()) { | 1157 if (o->style()->slowIsFlippedBlocksWritingMode()) { |
1158 IntPoint centerPoint = roundedIntPoint(transformState.mappedPoint())
; | 1158 IntPoint centerPoint = roundedIntPoint(transformState.mappedPoint())
; |
1159 transformState.move(toRenderBox(o)->flipForWritingModeIncludingColum
ns(centerPoint) - centerPoint); | 1159 transformState.move(toRenderBox(o)->flipForWritingModeIncludingColum
ns(centerPoint) - centerPoint); |
1160 } | 1160 } |
1161 mode &= ~ApplyContainerFlip; | 1161 mode &= ~ApplyContainerFlip; |
1162 } | 1162 } |
1163 | 1163 |
1164 LayoutSize containerOffset = offsetFromContainer(o, roundedLayoutPoint(trans
formState.mappedPoint())); | 1164 LayoutSize containerOffset = offsetFromContainer(o, roundedLayoutPoint(trans
formState.mappedPoint())); |
1165 | 1165 |
1166 bool preserve3D = mode & UseTransforms && (o->style()->preserves3D() || styl
e()->preserves3D()); | 1166 bool preserve3D = mode & UseTransforms && (o->style()->preserves3D() || styl
e()->preserves3D()); |
1167 if (mode & UseTransforms && shouldUseTransformFromContainer(o)) { | 1167 if (mode & UseTransforms && shouldUseTransformFromContainer(o)) { |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1410 container = this; | 1410 container = this; |
1411 | 1411 |
1412 FloatPoint absPos = container->localToAbsolute(); | 1412 FloatPoint absPos = container->localToAbsolute(); |
1413 region.bounds.setX(absPos.x() + region.bounds.x()); | 1413 region.bounds.setX(absPos.x() + region.bounds.x()); |
1414 region.bounds.setY(absPos.y() + region.bounds.y()); | 1414 region.bounds.setY(absPos.y() + region.bounds.y()); |
1415 | 1415 |
1416 regions.append(region); | 1416 regions.append(region); |
1417 } | 1417 } |
1418 | 1418 |
1419 } // namespace blink | 1419 } // namespace blink |
OLD | NEW |