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) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
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 890 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
901 } | 901 } |
902 | 902 |
903 void Node::detach(const AttachContext& context) | 903 void Node::detach(const AttachContext& context) |
904 { | 904 { |
905 ASSERT(document().lifecycle().stateAllowsDetach()); | 905 ASSERT(document().lifecycle().stateAllowsDetach()); |
906 DocumentLifecycle::DetachScope willDetach(document().lifecycle()); | 906 DocumentLifecycle::DetachScope willDetach(document().lifecycle()); |
907 | 907 |
908 if (layoutObject()) | 908 if (layoutObject()) |
909 layoutObject()->destroyAndCleanupAnonymousWrappers(); | 909 layoutObject()->destroyAndCleanupAnonymousWrappers(); |
910 setLayoutObject(nullptr); | 910 setLayoutObject(nullptr); |
911 | |
912 setStyleChange(NeedsReattachStyleChange); | 911 setStyleChange(NeedsReattachStyleChange); |
913 clearChildNeedsStyleInvalidation(); | 912 clearChildNeedsStyleInvalidation(); |
914 } | 913 } |
915 | 914 |
916 void Node::reattachWhitespaceSiblingsIfNeeded(Text* start) | 915 void Node::reattachWhitespaceSiblingsIfNeeded(Text* start) |
917 { | 916 { |
918 ScriptForbiddenScope forbidScriptDuringRawIteration; | 917 ScriptForbiddenScope forbidScriptDuringRawIteration; |
919 for (Node* sibling = start; sibling; sibling = sibling->nextSibling()) { | 918 for (Node* sibling = start; sibling; sibling = sibling->nextSibling()) { |
920 if (sibling->isTextNode() && toText(sibling)->containsOnlyWhitespace())
{ | 919 if (sibling->isTextNode() && toText(sibling)->containsOnlyWhitespace())
{ |
921 bool hadLayoutObject = !!sibling->layoutObject(); | 920 bool hadLayoutObject = !!sibling->layoutObject(); |
(...skipping 1448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2370 | 2369 |
2371 void showNodePath(const blink::Node* node) | 2370 void showNodePath(const blink::Node* node) |
2372 { | 2371 { |
2373 if (node) | 2372 if (node) |
2374 node->showNodePathForThis(); | 2373 node->showNodePathForThis(); |
2375 else | 2374 else |
2376 fprintf(stderr, "Cannot showNodePath for (nil)\n"); | 2375 fprintf(stderr, "Cannot showNodePath for (nil)\n"); |
2377 } | 2376 } |
2378 | 2377 |
2379 #endif | 2378 #endif |
OLD | NEW |