| 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-2011, 2014 Apple Inc. All rights reserved. | 5 * Copyright (C) 2004-2011, 2014 Apple Inc. All rights 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 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 bool supportsAltText(); | 247 bool supportsAltText(); |
| 248 | 248 |
| 249 // Other methods (not part of DOM) | 249 // Other methods (not part of DOM) |
| 250 | 250 |
| 251 bool isElementNode() const { return getFlag(IsElementFlag); } | 251 bool isElementNode() const { return getFlag(IsElementFlag); } |
| 252 bool isContainerNode() const { return getFlag(IsContainerFlag); } | 252 bool isContainerNode() const { return getFlag(IsContainerFlag); } |
| 253 bool isTextNode() const { return getFlag(IsTextFlag); } | 253 bool isTextNode() const { return getFlag(IsTextFlag); } |
| 254 bool isHTMLElement() const { return getFlag(IsHTMLFlag); } | 254 bool isHTMLElement() const { return getFlag(IsHTMLFlag); } |
| 255 bool isSVGElement() const { return getFlag(IsSVGFlag); } | 255 bool isSVGElement() const { return getFlag(IsSVGFlag); } |
| 256 | 256 |
| 257 bool isPseudoElement() const { return getPseudoId() != NOPSEUDO; } | 257 bool isPseudoElement() const { return getPseudoId() != PseudoIdNone; } |
| 258 bool isBeforePseudoElement() const { return getPseudoId() == BEFORE; } | 258 bool isBeforePseudoElement() const { return getPseudoId() == PseudoIdBefore;
} |
| 259 bool isAfterPseudoElement() const { return getPseudoId() == AFTER; } | 259 bool isAfterPseudoElement() const { return getPseudoId() == PseudoIdAfter; } |
| 260 bool isFirstLetterPseudoElement() const { return getPseudoId() == FIRST_LETT
ER; } | 260 bool isFirstLetterPseudoElement() const { return getPseudoId() == PseudoIdFi
rstLetter; } |
| 261 virtual PseudoId getPseudoId() const { return NOPSEUDO; } | 261 virtual PseudoId getPseudoId() const { return PseudoIdNone; } |
| 262 | 262 |
| 263 bool isCustomElement() const { return getFlag(CustomElementFlag); } | 263 bool isCustomElement() const { return getFlag(CustomElementFlag); } |
| 264 enum CustomElementState { | 264 enum CustomElementState { |
| 265 NotCustomElement = 0, | 265 NotCustomElement = 0, |
| 266 WaitingForUpgrade = 1 << 0, | 266 WaitingForUpgrade = 1 << 0, |
| 267 Upgraded = 1 << 1 | 267 Upgraded = 1 << 1 |
| 268 }; | 268 }; |
| 269 CustomElementState getCustomElementState() const | 269 CustomElementState getCustomElementState() const |
| 270 { | 270 { |
| 271 return isCustomElement() | 271 return isCustomElement() |
| (...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 554 // Returns true if recalcStyle should be called on the object, if there is s
uch a method (on Document and Element). | 554 // Returns true if recalcStyle should be called on the object, if there is s
uch a method (on Document and Element). |
| 555 bool shouldCallRecalcStyle(StyleRecalcChange); | 555 bool shouldCallRecalcStyle(StyleRecalcChange); |
| 556 | 556 |
| 557 // Wrapper for nodes that don't have a layoutObject, but still cache the sty
le (like HTMLOptionElement). | 557 // Wrapper for nodes that don't have a layoutObject, but still cache the sty
le (like HTMLOptionElement). |
| 558 ComputedStyle* mutableComputedStyle() const; | 558 ComputedStyle* mutableComputedStyle() const; |
| 559 const ComputedStyle* computedStyle() const; | 559 const ComputedStyle* computedStyle() const; |
| 560 const ComputedStyle* parentComputedStyle() const; | 560 const ComputedStyle* parentComputedStyle() const; |
| 561 | 561 |
| 562 const ComputedStyle& computedStyleRef() const; | 562 const ComputedStyle& computedStyleRef() const; |
| 563 | 563 |
| 564 const ComputedStyle* ensureComputedStyle(PseudoId pseudoElementSpecifier = N
OPSEUDO) { return virtualEnsureComputedStyle(pseudoElementSpecifier); } | 564 const ComputedStyle* ensureComputedStyle(PseudoId pseudoElementSpecifier = P
seudoIdNone) { return virtualEnsureComputedStyle(pseudoElementSpecifier); } |
| 565 | 565 |
| 566 // -------------------------------------------------------------------------
---- | 566 // -------------------------------------------------------------------------
---- |
| 567 // Notification of document structure changes (see ContainerNode.h for more
notification methods) | 567 // Notification of document structure changes (see ContainerNode.h for more
notification methods) |
| 568 // | 568 // |
| 569 // At first, WebKit notifies the node that it has been inserted into the doc
ument. This is called during document parsing, and also | 569 // At first, WebKit notifies the node that it has been inserted into the doc
ument. This is called during document parsing, and also |
| 570 // when a node is added through the DOM methods insertBefore(), appendChild(
) or replaceChild(). The call happens _after_ the node has been added to the tre
e. | 570 // when a node is added through the DOM methods insertBefore(), appendChild(
) or replaceChild(). The call happens _after_ the node has been added to the tre
e. |
| 571 // This is similar to the DOMNodeInsertedIntoDocument DOM event, but does no
t require the overhead of event | 571 // This is similar to the DOMNodeInsertedIntoDocument DOM event, but does no
t require the overhead of event |
| 572 // dispatching. | 572 // dispatching. |
| 573 // | 573 // |
| 574 // WebKit notifies this callback regardless if the subtree of the node is a
document tree or a floating subtree. | 574 // WebKit notifies this callback regardless if the subtree of the node is a
document tree or a floating subtree. |
| (...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 817 bool isUserActionElementInActiveChain() const; | 817 bool isUserActionElementInActiveChain() const; |
| 818 bool isUserActionElementHovered() const; | 818 bool isUserActionElementHovered() const; |
| 819 bool isUserActionElementFocused() const; | 819 bool isUserActionElementFocused() const; |
| 820 | 820 |
| 821 void recalcDistribution(); | 821 void recalcDistribution(); |
| 822 | 822 |
| 823 void setStyleChange(StyleChangeType); | 823 void setStyleChange(StyleChangeType); |
| 824 | 824 |
| 825 virtual ComputedStyle* nonLayoutObjectComputedStyle() const { return nullptr
; } | 825 virtual ComputedStyle* nonLayoutObjectComputedStyle() const { return nullptr
; } |
| 826 | 826 |
| 827 virtual const ComputedStyle* virtualEnsureComputedStyle(PseudoId = NOPSEUDO)
; | 827 virtual const ComputedStyle* virtualEnsureComputedStyle(PseudoId = PseudoIdN
one); |
| 828 | 828 |
| 829 void trackForDebugging(); | 829 void trackForDebugging(); |
| 830 | 830 |
| 831 WillBeHeapVector<OwnPtrWillBeMember<MutationObserverRegistration>>* mutation
ObserverRegistry(); | 831 WillBeHeapVector<OwnPtrWillBeMember<MutationObserverRegistration>>* mutation
ObserverRegistry(); |
| 832 WillBeHeapHashSet<RawPtrWillBeMember<MutationObserverRegistration>>* transie
ntMutationObserverRegistry(); | 832 WillBeHeapHashSet<RawPtrWillBeMember<MutationObserverRegistration>>* transie
ntMutationObserverRegistry(); |
| 833 | 833 |
| 834 uint32_t m_nodeFlags; | 834 uint32_t m_nodeFlags; |
| 835 RawPtrWillBeMember<ContainerNode> m_parentOrShadowHostNode; | 835 RawPtrWillBeMember<ContainerNode> m_parentOrShadowHostNode; |
| 836 RawPtrWillBeMember<TreeScope> m_treeScope; | 836 RawPtrWillBeMember<TreeScope> m_treeScope; |
| 837 RawPtrWillBeMember<Node> m_previous; | 837 RawPtrWillBeMember<Node> m_previous; |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 928 } // namespace blink | 928 } // namespace blink |
| 929 | 929 |
| 930 #ifndef NDEBUG | 930 #ifndef NDEBUG |
| 931 // Outside the WebCore namespace for ease of invocation from gdb. | 931 // Outside the WebCore namespace for ease of invocation from gdb. |
| 932 void showNode(const blink::Node*); | 932 void showNode(const blink::Node*); |
| 933 void showTree(const blink::Node*); | 933 void showTree(const blink::Node*); |
| 934 void showNodePath(const blink::Node*); | 934 void showNodePath(const blink::Node*); |
| 935 #endif | 935 #endif |
| 936 | 936 |
| 937 #endif // Node_h | 937 #endif // Node_h |
| OLD | NEW |