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, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 6 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
474 // Returns the document associated with this node. A Document node returns i
tself. | 474 // Returns the document associated with this node. A Document node returns i
tself. |
475 Document& document() const | 475 Document& document() const |
476 { | 476 { |
477 ASSERT(this); | 477 ASSERT(this); |
478 ASSERT(documentInternal()); | 478 ASSERT(documentInternal()); |
479 return *documentInternal(); | 479 return *documentInternal(); |
480 } | 480 } |
481 | 481 |
482 TreeScope& treeScope() const { return *m_treeScope; } | 482 TreeScope& treeScope() const { return *m_treeScope; } |
483 | 483 |
| 484 bool inActiveDocument() const; |
| 485 |
484 // Returns true if this node is associated with a document and is in its ass
ociated document's | 486 // Returns true if this node is associated with a document and is in its ass
ociated document's |
485 // node tree, false otherwise. | 487 // node tree, false otherwise. |
486 bool inDocument() const | 488 bool inDocument() const |
487 { | 489 { |
488 ASSERT(documentInternal() || !getFlag(InDocumentFlag)); | 490 ASSERT(documentInternal() || !getFlag(InDocumentFlag)); |
489 return getFlag(InDocumentFlag); | 491 return getFlag(InDocumentFlag); |
490 } | 492 } |
491 bool isInShadowTree() const { return getFlag(IsInShadowTreeFlag); } | 493 bool isInShadowTree() const { return getFlag(IsInShadowTreeFlag); } |
492 bool isInTreeScope() const { return getFlag(static_cast<NodeFlags>(InDocumen
tFlag | IsInShadowTreeFlag)); } | 494 bool isInTreeScope() const { return getFlag(static_cast<NodeFlags>(InDocumen
tFlag | IsInShadowTreeFlag)); } |
493 | 495 |
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
943 | 945 |
944 } // namespace WebCore | 946 } // namespace WebCore |
945 | 947 |
946 #ifndef NDEBUG | 948 #ifndef NDEBUG |
947 // Outside the WebCore namespace for ease of invocation from gdb. | 949 // Outside the WebCore namespace for ease of invocation from gdb. |
948 void showTree(const WebCore::Node*); | 950 void showTree(const WebCore::Node*); |
949 void showNodePath(const WebCore::Node*); | 951 void showNodePath(const WebCore::Node*); |
950 #endif | 952 #endif |
951 | 953 |
952 #endif | 954 #endif |
OLD | NEW |