| 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 * Copyright (C) 2011 Google Inc. All rights reserved. | 8 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 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 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 { | 110 { |
| 111 DCHECK(!didMoveToNewDocumentWasCalled); | 111 DCHECK(!didMoveToNewDocumentWasCalled); |
| 112 ASSERT_UNUSED(oldDocument, oldDocument == oldDocumentDidMoveToNewDocumentWas
CalledWith); | 112 ASSERT_UNUSED(oldDocument, oldDocument == oldDocumentDidMoveToNewDocumentWas
CalledWith); |
| 113 didMoveToNewDocumentWasCalled = true; | 113 didMoveToNewDocumentWasCalled = true; |
| 114 } | 114 } |
| 115 #endif | 115 #endif |
| 116 | 116 |
| 117 inline void TreeScopeAdopter::updateTreeScope(Node& node) const | 117 inline void TreeScopeAdopter::updateTreeScope(Node& node) const |
| 118 { | 118 { |
| 119 DCHECK(!node.isTreeScope()); | 119 DCHECK(!node.isTreeScope()); |
| 120 DCHECK(node.treeScope() == oldScope()); | 120 DCHECK(node.treeScopeOrDocument() == oldScope()); |
| 121 #if !ENABLE(OILPAN) | 121 #if !ENABLE(OILPAN) |
| 122 newScope().guardRef(); | 122 newScope().guardRef(); |
| 123 oldScope().guardDeref(); | 123 oldScope().guardDeref(); |
| 124 #endif | 124 #endif |
| 125 node.setTreeScope(m_newScope); | 125 node.setTreeScope(m_newScope); |
| 126 } | 126 } |
| 127 | 127 |
| 128 inline void TreeScopeAdopter::moveNodeToNewDocument(Node& node, Document& oldDoc
ument, Document& newDocument) const | 128 inline void TreeScopeAdopter::moveNodeToNewDocument(Node& node, Document& oldDoc
ument, Document& newDocument) const |
| 129 { | 129 { |
| 130 DCHECK_NE(oldDocument, newDocument); | 130 DCHECK_NE(oldDocument, newDocument); |
| (...skipping 14 matching lines...) Expand all Loading... |
| 145 oldDocumentDidMoveToNewDocumentWasCalledWith = &oldDocument; | 145 oldDocumentDidMoveToNewDocumentWasCalledWith = &oldDocument; |
| 146 #endif | 146 #endif |
| 147 | 147 |
| 148 node.didMoveToNewDocument(oldDocument); | 148 node.didMoveToNewDocument(oldDocument); |
| 149 #if DCHECK_IS_ON() | 149 #if DCHECK_IS_ON() |
| 150 DCHECK(didMoveToNewDocumentWasCalled); | 150 DCHECK(didMoveToNewDocumentWasCalled); |
| 151 #endif | 151 #endif |
| 152 } | 152 } |
| 153 | 153 |
| 154 } // namespace blink | 154 } // namespace blink |
| OLD | NEW |