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 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. |
7 * Copyright (C) 2010 Google Inc. All rights reserved. | 7 * Copyright (C) 2010 Google Inc. All rights reserved. |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
384 PaintInvalidationState newPaintInvalidationState(paintInvalidationState, *th
is); | 384 PaintInvalidationState newPaintInvalidationState(paintInvalidationState, *th
is); |
385 if (!shouldCheckForPaintInvalidation(newPaintInvalidationState)) | 385 if (!shouldCheckForPaintInvalidation(newPaintInvalidationState)) |
386 return; | 386 return; |
387 | 387 |
388 if (mayNeedPaintInvalidationSubtree()) | 388 if (mayNeedPaintInvalidationSubtree()) |
389 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); | 389 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); |
390 | 390 |
391 LayoutRect previousPaintInvalidationRect = this->previousPaintInvalidationRe
ct(); | 391 LayoutRect previousPaintInvalidationRect = this->previousPaintInvalidationRe
ct(); |
392 LayoutPoint previousPosition = previousPositionFromPaintInvalidationBacking(
); | 392 LayoutPoint previousPosition = previousPositionFromPaintInvalidationBacking(
); |
393 PaintInvalidationReason reason = invalidatePaintIfNeeded(newPaintInvalidatio
nState); | 393 PaintInvalidationReason reason = invalidatePaintIfNeeded(newPaintInvalidatio
nState); |
394 clearPaintInvalidationFlags(newPaintInvalidationState); | 394 clearPaintInvalidationFlags(); |
395 | 395 |
396 if (previousPosition != previousPositionFromPaintInvalidationBacking()) | 396 if (previousPosition != previousPositionFromPaintInvalidationBacking()) |
397 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); | 397 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); |
398 | 398 |
399 // TODO(wangxianzhu): Combine this function into LayoutObject::invalidateTre
eIfNeeded() when removing the following workarounds. | 399 // TODO(wangxianzhu): Combine this function into LayoutObject::invalidateTre
eIfNeeded() when removing the following workarounds. |
400 | 400 |
401 // TODO(wangxianzhu): This is a workaround for crbug.com/533277. Will remove
when we enable paint offset caching. | 401 // TODO(wangxianzhu): This is a workaround for crbug.com/533277. Will remove
when we enable paint offset caching. |
402 if (reason != PaintInvalidationNone && hasPercentageTransform(styleRef())) | 402 if (reason != PaintInvalidationNone && hasPercentageTransform(styleRef())) |
403 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); | 403 newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinConta
iner(); |
404 | 404 |
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1135 if (rootElementStyle->hasBackground()) | 1135 if (rootElementStyle->hasBackground()) |
1136 return false; | 1136 return false; |
1137 | 1137 |
1138 if (node() != document().firstBodyElement()) | 1138 if (node() != document().firstBodyElement()) |
1139 return false; | 1139 return false; |
1140 | 1140 |
1141 return true; | 1141 return true; |
1142 } | 1142 } |
1143 | 1143 |
1144 } // namespace blink | 1144 } // namespace blink |
OLD | NEW |