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