| 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) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv
ed. |
| 7 * Copyright (C) 2009 Google Inc. All rights reserved. | 7 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
| 9 * | 9 * |
| 10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
| (...skipping 1346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1357 | 1357 |
| 1358 const char* RenderObject::invalidationReasonToString(InvalidationReason reason)
const | 1358 const char* RenderObject::invalidationReasonToString(InvalidationReason reason)
const |
| 1359 { | 1359 { |
| 1360 switch (reason) { | 1360 switch (reason) { |
| 1361 case InvalidationNone: | 1361 case InvalidationNone: |
| 1362 return "none"; | 1362 return "none"; |
| 1363 case InvalidationIncremental: | 1363 case InvalidationIncremental: |
| 1364 return "incremental"; | 1364 return "incremental"; |
| 1365 case InvalidationFull: | 1365 case InvalidationFull: |
| 1366 return "full"; | 1366 return "full"; |
| 1367 case InvalidationBorderFitLines: | |
| 1368 return "border fit lines"; | |
| 1369 case InvalidationBorderBoxChange: | 1367 case InvalidationBorderBoxChange: |
| 1370 return "border box change"; | 1368 return "border box change"; |
| 1371 case InvalidationBoundsChange: | 1369 case InvalidationBoundsChange: |
| 1372 return "bounds change"; | 1370 return "bounds change"; |
| 1373 case InvalidationLocationChange: | 1371 case InvalidationLocationChange: |
| 1374 return "location change"; | 1372 return "location change"; |
| 1375 case InvalidationScroll: | 1373 case InvalidationScroll: |
| 1376 return "scroll"; | 1374 return "scroll"; |
| 1377 case InvalidationSelection: | 1375 case InvalidationSelection: |
| 1378 return "selection"; | 1376 return "selection"; |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1438 fullyInvalidatePaint(paintInvalidationContainer, invalidationReason, oldBoun
ds, newBounds); | 1436 fullyInvalidatePaint(paintInvalidationContainer, invalidationReason, oldBoun
ds, newBounds); |
| 1439 return invalidationReason; | 1437 return invalidationReason; |
| 1440 } | 1438 } |
| 1441 | 1439 |
| 1442 InvalidationReason RenderObject::getPaintInvalidationReason(const RenderLayerMod
elObject& paintInvalidationContainer, | 1440 InvalidationReason RenderObject::getPaintInvalidationReason(const RenderLayerMod
elObject& paintInvalidationContainer, |
| 1443 const LayoutRect& oldBounds, const LayoutPoint& oldLocation, const LayoutRec
t& newBounds, const LayoutPoint& newLocation) | 1441 const LayoutRect& oldBounds, const LayoutPoint& oldLocation, const LayoutRec
t& newBounds, const LayoutPoint& newLocation) |
| 1444 { | 1442 { |
| 1445 if (shouldDoFullPaintInvalidation()) | 1443 if (shouldDoFullPaintInvalidation()) |
| 1446 return InvalidationFull; | 1444 return InvalidationFull; |
| 1447 | 1445 |
| 1448 // Presumably a background or a border exists if border-fit:lines was specif
ied. | |
| 1449 if (style()->borderFit() == BorderFitLines) | |
| 1450 return InvalidationBorderFitLines; | |
| 1451 | |
| 1452 if (compositingState() != PaintsIntoOwnBacking && newLocation != oldLocation
) | 1446 if (compositingState() != PaintsIntoOwnBacking && newLocation != oldLocation
) |
| 1453 return InvalidationLocationChange; | 1447 return InvalidationLocationChange; |
| 1454 | 1448 |
| 1455 // If the bounds are the same then we know that none of the statements below | 1449 // If the bounds are the same then we know that none of the statements below |
| 1456 // can match, so we can early out since we will not need to do any | 1450 // can match, so we can early out since we will not need to do any |
| 1457 // invalidation. | 1451 // invalidation. |
| 1458 if (oldBounds == newBounds) | 1452 if (oldBounds == newBounds) |
| 1459 return InvalidationNone; | 1453 return InvalidationNone; |
| 1460 | 1454 |
| 1461 // If we shifted, we don't know the exact reason so we are conservative and
trigger a full invalidation. Shifting could | 1455 // If we shifted, we don't know the exact reason so we are conservative and
trigger a full invalidation. Shifting could |
| (...skipping 1388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2850 { | 2844 { |
| 2851 if (object1) { | 2845 if (object1) { |
| 2852 const blink::RenderObject* root = object1; | 2846 const blink::RenderObject* root = object1; |
| 2853 while (root->parent()) | 2847 while (root->parent()) |
| 2854 root = root->parent(); | 2848 root = root->parent(); |
| 2855 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); | 2849 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); |
| 2856 } | 2850 } |
| 2857 } | 2851 } |
| 2858 | 2852 |
| 2859 #endif | 2853 #endif |
| OLD | NEW |