OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights |
3 * reserved. | 3 * reserved. |
4 * | 4 * |
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
6 * | 6 * |
7 * Other contributors: | 7 * Other contributors: |
8 * Robert O'Callahan <roc+@cs.cmu.edu> | 8 * Robert O'Callahan <roc+@cs.cmu.edu> |
9 * David Baron <dbaron@fas.harvard.edu> | 9 * David Baron <dbaron@fas.harvard.edu> |
10 * Christian Biesinger <cbiesinger@web.de> | 10 * Christian Biesinger <cbiesinger@web.de> |
(...skipping 1285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1296 if (old_child->PreviousSibling()) | 1296 if (old_child->PreviousSibling()) |
1297 old_child->PreviousSibling()->SetNextSibling(old_child->NextSibling()); | 1297 old_child->PreviousSibling()->SetNextSibling(old_child->NextSibling()); |
1298 if (old_child->NextSibling()) | 1298 if (old_child->NextSibling()) |
1299 old_child->NextSibling()->SetPreviousSibling(old_child->PreviousSibling()); | 1299 old_child->NextSibling()->SetPreviousSibling(old_child->PreviousSibling()); |
1300 | 1300 |
1301 if (first_ == old_child) | 1301 if (first_ == old_child) |
1302 first_ = old_child->NextSibling(); | 1302 first_ = old_child->NextSibling(); |
1303 if (last_ == old_child) | 1303 if (last_ == old_child) |
1304 last_ = old_child->PreviousSibling(); | 1304 last_ = old_child->PreviousSibling(); |
1305 | 1305 |
1306 if (Compositor()) { | 1306 if (!GetLayoutObject().DocumentBeingDestroyed()) { |
1307 if (!old_child->StackingNode()->IsStacked() && | 1307 if (Compositor()) { |
1308 !GetLayoutObject().DocumentBeingDestroyed()) | 1308 if (!old_child->StackingNode()->IsStacked()) |
1309 Compositor()->SetNeedsCompositingUpdate(kCompositingUpdateRebuildTree); | 1309 Compositor()->SetNeedsCompositingUpdate(kCompositingUpdateRebuildTree); |
1310 } | 1310 } |
1311 | 1311 |
1312 if (old_child->StackingNode()->IsStacked() || old_child->FirstChild()) { | 1312 if (old_child->StackingNode()->IsStacked() || old_child->FirstChild()) { |
1313 // Dirty the z-order list in which we are contained. When called via the | 1313 // Dirty the z-order list in which we are contained. When called via the |
1314 // reattachment process in removeOnlyThisLayer, the layer may already be | 1314 // reattachment process in removeOnlyThisLayer, the layer may already be |
1315 // disconnected from the main layer tree, so we need to null-check the | 1315 // disconnected from the main layer tree, so we need to null-check the |
1316 // |stackingContext| value. | 1316 // |stackingContext| value. |
1317 old_child->StackingNode()->DirtyStackingContextZOrderLists(); | 1317 old_child->StackingNode()->DirtyStackingContextZOrderLists(); |
| 1318 } |
1318 } | 1319 } |
1319 | 1320 |
1320 if (GetLayoutObject().Style()->Visibility() != EVisibility::kVisible) | 1321 if (GetLayoutObject().Style()->Visibility() != EVisibility::kVisible) |
1321 DirtyVisibleContentStatus(); | 1322 DirtyVisibleContentStatus(); |
1322 | 1323 |
1323 old_child->SetPreviousSibling(0); | 1324 old_child->SetPreviousSibling(0); |
1324 old_child->SetNextSibling(0); | 1325 old_child->SetNextSibling(0); |
1325 old_child->parent_ = 0; | 1326 old_child->parent_ = 0; |
1326 | 1327 |
1327 // Remove any ancestor overflow layers which descended into the removed child. | 1328 // Remove any ancestor overflow layers which descended into the removed child. |
(...skipping 1988 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3316 } | 3317 } |
3317 | 3318 |
3318 void showLayerTree(const blink::LayoutObject* layoutObject) { | 3319 void showLayerTree(const blink::LayoutObject* layoutObject) { |
3319 if (!layoutObject) { | 3320 if (!layoutObject) { |
3320 LOG(INFO) << "Cannot showLayerTree. Root is (nil)"; | 3321 LOG(INFO) << "Cannot showLayerTree. Root is (nil)"; |
3321 return; | 3322 return; |
3322 } | 3323 } |
3323 showLayerTree(layoutObject->EnclosingLayer()); | 3324 showLayerTree(layoutObject->EnclosingLayer()); |
3324 } | 3325 } |
3325 #endif | 3326 #endif |
OLD | NEW |