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 1122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1133 | 1133 |
1134 if (container->hasOverflowClip()) | 1134 if (container->hasOverflowClip()) |
1135 offset -= toLayoutBox(container)->scrolledContentOffset(); | 1135 offset -= toLayoutBox(container)->scrolledContentOffset(); |
1136 | 1136 |
1137 if (offsetDependsOnPoint) | 1137 if (offsetDependsOnPoint) |
1138 *offsetDependsOnPoint = (container->isBox() && container->style()->isFli
ppedBlocksWritingMode()) || container->isLayoutFlowThread(); | 1138 *offsetDependsOnPoint = (container->isBox() && container->style()->isFli
ppedBlocksWritingMode()) || container->isLayoutFlowThread(); |
1139 | 1139 |
1140 return offset; | 1140 return offset; |
1141 } | 1141 } |
1142 | 1142 |
| 1143 PaintLayerType LayoutInline::layerTypeRequired() const |
| 1144 { |
| 1145 return isInFlowPositioned() || createsGroup() || hasClipPath() || style()->s
houldCompositeForCurrentAnimations() |
| 1146 || style()->hasCompositorProxy() || style()->containsPaint() ? NormalPa
intLayer : NoPaintLayer; |
| 1147 } |
| 1148 |
1143 void LayoutInline::mapLocalToContainer(const LayoutBoxModelObject* paintInvalida
tionContainer, TransformState& transformState, MapCoordinatesFlags mode, bool* w
asFixed, const PaintInvalidationState* paintInvalidationState) const | 1149 void LayoutInline::mapLocalToContainer(const LayoutBoxModelObject* paintInvalida
tionContainer, TransformState& transformState, MapCoordinatesFlags mode, bool* w
asFixed, const PaintInvalidationState* paintInvalidationState) const |
1144 { | 1150 { |
1145 if (paintInvalidationContainer == this) | 1151 if (paintInvalidationContainer == this) |
1146 return; | 1152 return; |
1147 | 1153 |
1148 if (paintInvalidationState && paintInvalidationState->canMapToContainer(pain
tInvalidationContainer)) { | 1154 if (paintInvalidationState && paintInvalidationState->canMapToContainer(pain
tInvalidationContainer)) { |
1149 LayoutSize offset = paintInvalidationState->paintOffset(); | 1155 LayoutSize offset = paintInvalidationState->paintOffset(); |
1150 if (style()->hasInFlowPosition() && layer()) | 1156 if (style()->hasInFlowPosition() && layer()) |
1151 offset += layer()->offsetForInFlowPosition(); | 1157 offset += layer()->offsetForInFlowPosition(); |
1152 transformState.move(offset); | 1158 transformState.move(offset); |
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1421 { | 1427 { |
1422 LayoutBoxModelObject::invalidateDisplayItemClients(paintInvalidationContaine
r, invalidationReason, paintInvalidationRect); | 1428 LayoutBoxModelObject::invalidateDisplayItemClients(paintInvalidationContaine
r, invalidationReason, paintInvalidationRect); |
1423 | 1429 |
1424 // Use the paintInvalidationRect of LayoutInline for inline boxes, which sav
es the cost to calculate paint invalidation rect | 1430 // Use the paintInvalidationRect of LayoutInline for inline boxes, which sav
es the cost to calculate paint invalidation rect |
1425 // for every inline box. This won't cause more rasterization invalidations b
ecause the whole LayoutInline is being invalidated. | 1431 // for every inline box. This won't cause more rasterization invalidations b
ecause the whole LayoutInline is being invalidated. |
1426 for (InlineFlowBox* box = firstLineBox(); box; box = box->nextLineBox()) | 1432 for (InlineFlowBox* box = firstLineBox(); box; box = box->nextLineBox()) |
1427 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(*box, in
validationReason, paintInvalidationRect); | 1433 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(*box, in
validationReason, paintInvalidationRect); |
1428 } | 1434 } |
1429 | 1435 |
1430 } // namespace blink | 1436 } // namespace blink |
OLD | NEW |