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 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) | 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) |
8 * Copyright (C) 2010 Google Inc. All rights reserved. | 8 * Copyright (C) 2010 Google Inc. All rights reserved. |
9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
10 * Copyright (C) 2012 Samsung Electronics. All rights reserved. | 10 * Copyright (C) 2012 Samsung Electronics. All rights reserved. |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 #include "wtf/MathExtras.h" | 82 #include "wtf/MathExtras.h" |
83 | 83 |
84 namespace blink { | 84 namespace blink { |
85 | 85 |
86 using namespace HTMLNames; | 86 using namespace HTMLNames; |
87 | 87 |
88 class ListAttributeTargetObserver : public IdTargetObserver { | 88 class ListAttributeTargetObserver : public IdTargetObserver { |
89 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; | 89 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; |
90 public: | 90 public: |
91 static PassOwnPtrWillBeRawPtr<ListAttributeTargetObserver> create(const Atom
icString& id, HTMLInputElement*); | 91 static PassOwnPtrWillBeRawPtr<ListAttributeTargetObserver> create(const Atom
icString& id, HTMLInputElement*); |
92 virtual void trace(Visitor*) override; | 92 DECLARE_VIRTUAL_TRACE(); |
93 virtual void idTargetChanged() override; | 93 virtual void idTargetChanged() override; |
94 | 94 |
95 private: | 95 private: |
96 ListAttributeTargetObserver(const AtomicString& id, HTMLInputElement*); | 96 ListAttributeTargetObserver(const AtomicString& id, HTMLInputElement*); |
97 | 97 |
98 RawPtrWillBeMember<HTMLInputElement> m_element; | 98 RawPtrWillBeMember<HTMLInputElement> m_element; |
99 }; | 99 }; |
100 | 100 |
101 // FIXME: According to HTML4, the length attribute's value can be arbitrarily | 101 // FIXME: According to HTML4, the length attribute's value can be arbitrarily |
102 // large. However, due to https://bugs.webkit.org/show_bug.cgi?id=14536 things | 102 // large. However, due to https://bugs.webkit.org/show_bug.cgi?id=14536 things |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 } | 136 } |
137 | 137 |
138 PassRefPtrWillBeRawPtr<HTMLInputElement> HTMLInputElement::create(Document& docu
ment, HTMLFormElement* form, bool createdByParser) | 138 PassRefPtrWillBeRawPtr<HTMLInputElement> HTMLInputElement::create(Document& docu
ment, HTMLFormElement* form, bool createdByParser) |
139 { | 139 { |
140 RefPtrWillBeRawPtr<HTMLInputElement> inputElement = adoptRefWillBeNoop(new H
TMLInputElement(document, form, createdByParser)); | 140 RefPtrWillBeRawPtr<HTMLInputElement> inputElement = adoptRefWillBeNoop(new H
TMLInputElement(document, form, createdByParser)); |
141 if (!createdByParser) | 141 if (!createdByParser) |
142 inputElement->ensureUserAgentShadowRoot(); | 142 inputElement->ensureUserAgentShadowRoot(); |
143 return inputElement.release(); | 143 return inputElement.release(); |
144 } | 144 } |
145 | 145 |
146 void HTMLInputElement::trace(Visitor* visitor) | 146 DEFINE_TRACE(HTMLInputElement) |
147 { | 147 { |
148 visitor->trace(m_inputType); | 148 visitor->trace(m_inputType); |
149 visitor->trace(m_inputTypeView); | 149 visitor->trace(m_inputTypeView); |
150 visitor->trace(m_listAttributeTargetObserver); | 150 visitor->trace(m_listAttributeTargetObserver); |
151 visitor->trace(m_imageLoader); | 151 visitor->trace(m_imageLoader); |
152 HTMLTextFormControlElement::trace(visitor); | 152 HTMLTextFormControlElement::trace(visitor); |
153 } | 153 } |
154 | 154 |
155 HTMLImageLoader& HTMLInputElement::ensureImageLoader() | 155 HTMLImageLoader& HTMLInputElement::ensureImageLoader() |
156 { | 156 { |
(...skipping 1620 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1777 { | 1777 { |
1778 return adoptPtrWillBeNoop(new ListAttributeTargetObserver(id, element)); | 1778 return adoptPtrWillBeNoop(new ListAttributeTargetObserver(id, element)); |
1779 } | 1779 } |
1780 | 1780 |
1781 ListAttributeTargetObserver::ListAttributeTargetObserver(const AtomicString& id,
HTMLInputElement* element) | 1781 ListAttributeTargetObserver::ListAttributeTargetObserver(const AtomicString& id,
HTMLInputElement* element) |
1782 : IdTargetObserver(element->treeScope().idTargetObserverRegistry(), id) | 1782 : IdTargetObserver(element->treeScope().idTargetObserverRegistry(), id) |
1783 , m_element(element) | 1783 , m_element(element) |
1784 { | 1784 { |
1785 } | 1785 } |
1786 | 1786 |
1787 void ListAttributeTargetObserver::trace(Visitor* visitor) | 1787 DEFINE_TRACE(ListAttributeTargetObserver) |
1788 { | 1788 { |
1789 visitor->trace(m_element); | 1789 visitor->trace(m_element); |
1790 IdTargetObserver::trace(visitor); | 1790 IdTargetObserver::trace(visitor); |
1791 } | 1791 } |
1792 | 1792 |
1793 void ListAttributeTargetObserver::idTargetChanged() | 1793 void ListAttributeTargetObserver::idTargetChanged() |
1794 { | 1794 { |
1795 m_element->listAttributeTargetChanged(); | 1795 m_element->listAttributeTargetChanged(); |
1796 } | 1796 } |
1797 | 1797 |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1912 void HTMLInputElement::ensurePrimaryContent() | 1912 void HTMLInputElement::ensurePrimaryContent() |
1913 { | 1913 { |
1914 m_inputTypeView->ensurePrimaryContent(); | 1914 m_inputTypeView->ensurePrimaryContent(); |
1915 } | 1915 } |
1916 | 1916 |
1917 bool HTMLInputElement::hasFallbackContent() const | 1917 bool HTMLInputElement::hasFallbackContent() const |
1918 { | 1918 { |
1919 return m_inputTypeView->hasFallbackContent(); | 1919 return m_inputTypeView->hasFallbackContent(); |
1920 } | 1920 } |
1921 } // namespace | 1921 } // namespace |
OLD | NEW |