| 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 Peter Kelly (pmk@post.com) | 4 * (C) 2001 Peter Kelly (pmk@post.com) |
| 5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved. | 6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved. |
| 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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 class CSSStyleDeclaration; | 43 class CSSStyleDeclaration; |
| 44 class ClientRect; | 44 class ClientRect; |
| 45 class ClientRectList; | 45 class ClientRectList; |
| 46 class DOMTokenList; | 46 class DOMTokenList; |
| 47 class Document; | 47 class Document; |
| 48 class ElementRareData; | 48 class ElementRareData; |
| 49 class ElementShadow; | 49 class ElementShadow; |
| 50 class ExceptionState; | 50 class ExceptionState; |
| 51 class Image; | 51 class Image; |
| 52 class IntSize; | 52 class IntSize; |
| 53 class LayoutCallback; |
| 53 class MutableStylePropertySet; | 54 class MutableStylePropertySet; |
| 54 class PaintingCallback; | 55 class PaintingCallback; |
| 55 class PropertySetCSSStyleDeclaration; | 56 class PropertySetCSSStyleDeclaration; |
| 56 class PseudoElement; | 57 class PseudoElement; |
| 57 class ShadowRoot; | 58 class ShadowRoot; |
| 58 class StylePropertySet; | 59 class StylePropertySet; |
| 59 | 60 |
| 60 enum SpellcheckAttributeState { | 61 enum SpellcheckAttributeState { |
| 61 SpellcheckAttributeTrue, | 62 SpellcheckAttributeTrue, |
| 62 SpellcheckAttributeFalse, | 63 SpellcheckAttributeFalse, |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 194 void setAnimationStyleChange(bool); | 195 void setAnimationStyleChange(bool); |
| 195 void setNeedsAnimationStyleRecalc(); | 196 void setNeedsAnimationStyleRecalc(); |
| 196 | 197 |
| 197 bool supportsStyleSharing() const; | 198 bool supportsStyleSharing() const; |
| 198 | 199 |
| 199 ElementShadow* shadow() const; | 200 ElementShadow* shadow() const; |
| 200 ElementShadow& ensureShadow(); | 201 ElementShadow& ensureShadow(); |
| 201 PassRefPtr<ShadowRoot> ensureShadowRoot(ExceptionState&); | 202 PassRefPtr<ShadowRoot> ensureShadowRoot(ExceptionState&); |
| 202 ShadowRoot* shadowRoot() const; | 203 ShadowRoot* shadowRoot() const; |
| 203 | 204 |
| 205 double x() const; |
| 206 void setX(double); |
| 207 |
| 208 double y() const; |
| 209 void setY(double); |
| 210 |
| 211 double width() const; |
| 212 void setWidth(double); |
| 213 |
| 214 double height() const; |
| 215 void setHeight(double); |
| 216 |
| 204 bool hasAuthorShadowRoot() const { return shadowRoot(); } | 217 bool hasAuthorShadowRoot() const { return shadowRoot(); } |
| 205 | 218 |
| 219 LayoutCallback* layoutManager() const; |
| 220 void setLayoutManager(PassOwnPtr<LayoutCallback>); |
| 221 |
| 206 RenderStyle* computedStyle(); | 222 RenderStyle* computedStyle(); |
| 207 | 223 |
| 208 bool isUpgradedCustomElement() const { return customElementState() == Upgrad
ed; } | 224 bool isUpgradedCustomElement() const { return customElementState() == Upgrad
ed; } |
| 209 bool isUnresolvedCustomElement() const { return customElementState() == Wait
ingForUpgrade; } | 225 bool isUnresolvedCustomElement() const { return customElementState() == Wait
ingForUpgrade; } |
| 210 | 226 |
| 211 AtomicString computeInheritedLanguage() const; | 227 AtomicString computeInheritedLanguage() const; |
| 212 | 228 |
| 213 virtual bool isURLAttribute(const Attribute&) const { return false; } | 229 virtual bool isURLAttribute(const Attribute&) const { return false; } |
| 214 | 230 |
| 215 virtual bool isLiveLink() const { return false; } | 231 virtual bool isLiveLink() const { return false; } |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 SpellcheckAttributeState spellcheckAttributeState() const; | 360 SpellcheckAttributeState spellcheckAttributeState() const; |
| 345 | 361 |
| 346 void createUniqueElementData(); | 362 void createUniqueElementData(); |
| 347 | 363 |
| 348 bool shouldInvalidateDistributionWhenAttributeChanged(ElementShadow*, const
QualifiedName&, const AtomicString&); | 364 bool shouldInvalidateDistributionWhenAttributeChanged(ElementShadow*, const
QualifiedName&, const AtomicString&); |
| 349 | 365 |
| 350 ElementRareData* elementRareData() const; | 366 ElementRareData* elementRareData() const; |
| 351 ElementRareData& ensureElementRareData(); | 367 ElementRareData& ensureElementRareData(); |
| 352 | 368 |
| 353 RefPtr<ElementData> m_elementData; | 369 RefPtr<ElementData> m_elementData; |
| 370 OwnPtr<LayoutCallback> m_layoutManager; |
| 354 }; | 371 }; |
| 355 | 372 |
| 356 DEFINE_NODE_TYPE_CASTS(Element, isElementNode()); | 373 DEFINE_NODE_TYPE_CASTS(Element, isElementNode()); |
| 357 template <typename T> bool isElementOfType(const Node&); | 374 template <typename T> bool isElementOfType(const Node&); |
| 358 template <> inline bool isElementOfType<const Element>(const Node& node) { retur
n node.isElementNode(); } | 375 template <> inline bool isElementOfType<const Element>(const Node& node) { retur
n node.isElementNode(); } |
| 359 template <typename T> inline bool isElementOfType(const Element& element) { retu
rn isElementOfType<T>(static_cast<const Node&>(element)); } | 376 template <typename T> inline bool isElementOfType(const Element& element) { retu
rn isElementOfType<T>(static_cast<const Node&>(element)); } |
| 360 template <> inline bool isElementOfType<const Element>(const Element&) { return
true; } | 377 template <> inline bool isElementOfType<const Element>(const Element&) { return
true; } |
| 361 | 378 |
| 362 // Type casting. | 379 // Type casting. |
| 363 template<typename T> inline T& toElement(Node& node) | 380 template<typename T> inline T& toElement(Node& node) |
| (...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 556 static PassRefPtr<T> create(const QualifiedName&, Document&) | 573 static PassRefPtr<T> create(const QualifiedName&, Document&) |
| 557 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \ | 574 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \ |
| 558 PassRefPtr<T> T::create(const QualifiedName& tagName, Document& document) \ | 575 PassRefPtr<T> T::create(const QualifiedName& tagName, Document& document) \ |
| 559 { \ | 576 { \ |
| 560 return adoptRef(new T(tagName, document)); \ | 577 return adoptRef(new T(tagName, document)); \ |
| 561 } | 578 } |
| 562 | 579 |
| 563 } // namespace | 580 } // namespace |
| 564 | 581 |
| 565 #endif // SKY_ENGINE_CORE_DOM_ELEMENT_H_ | 582 #endif // SKY_ENGINE_CORE_DOM_ELEMENT_H_ |
| OLD | NEW |