OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 17 matching lines...) Expand all Loading... | |
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
29 */ | 29 */ |
30 | 30 |
31 #include "config.h" | 31 #include "config.h" |
32 #include "public/web/WebInputElement.h" | 32 #include "public/web/WebInputElement.h" |
33 | 33 |
34 #include "core/HTMLNames.h" | 34 #include "core/HTMLNames.h" |
35 #include "core/dom/shadow/ElementShadow.h" | 35 #include "core/dom/shadow/ElementShadow.h" |
36 #include "core/dom/shadow/ShadowRoot.h" | 36 #include "core/dom/shadow/ShadowRoot.h" |
37 #include "core/html/HTMLDataListElement.h" | 37 #include "core/html/HTMLDataListElement.h" |
38 #include "core/html/HTMLDataListOptionsCollection.h" | |
haraken
2014/08/20 00:40:08
What is this #include for?
Inactive
2014/08/20 15:15:12
See comment below.
| |
38 #include "core/html/HTMLInputElement.h" | 39 #include "core/html/HTMLInputElement.h" |
39 #include "core/html/shadow/ShadowElementNames.h" | 40 #include "core/html/shadow/ShadowElementNames.h" |
40 #include "core/html/shadow/TextControlInnerElements.h" | 41 #include "core/html/shadow/TextControlInnerElements.h" |
41 #include "platform/RuntimeEnabledFeatures.h" | 42 #include "platform/RuntimeEnabledFeatures.h" |
42 #include "public/platform/WebString.h" | 43 #include "public/platform/WebString.h" |
43 #include "public/web/WebElementCollection.h" | 44 #include "public/web/WebElementCollection.h" |
44 #include "wtf/PassRefPtr.h" | 45 #include "wtf/PassRefPtr.h" |
45 | 46 |
46 namespace blink { | 47 namespace blink { |
47 | 48 |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
116 } | 117 } |
117 | 118 |
118 bool WebInputElement::isMultiple() const | 119 bool WebInputElement::isMultiple() const |
119 { | 120 { |
120 return constUnwrap<HTMLInputElement>()->multiple(); | 121 return constUnwrap<HTMLInputElement>()->multiple(); |
121 } | 122 } |
122 | 123 |
123 WebElementCollection WebInputElement::dataListOptions() const | 124 WebElementCollection WebInputElement::dataListOptions() const |
124 { | 125 { |
125 if (HTMLDataListElement* dataList = toHTMLDataListElement(constUnwrap<HTMLIn putElement>()->list())) | 126 if (HTMLDataListElement* dataList = toHTMLDataListElement(constUnwrap<HTMLIn putElement>()->list())) |
126 return WebElementCollection(dataList->options()); | 127 return WebElementCollection(dataList->options()); |
Inactive
2014/08/20 15:15:12
Here is it using dataList->options(), which now re
| |
127 return WebElementCollection(); | 128 return WebElementCollection(); |
128 } | 129 } |
129 | 130 |
130 WebString WebInputElement::localizeValue(const WebString& proposedValue) const | 131 WebString WebInputElement::localizeValue(const WebString& proposedValue) const |
131 { | 132 { |
132 return constUnwrap<HTMLInputElement>()->localizeValue(proposedValue); | 133 return constUnwrap<HTMLInputElement>()->localizeValue(proposedValue); |
133 } | 134 } |
134 | 135 |
135 int WebInputElement::defaultMaxLength() | 136 int WebInputElement::defaultMaxLength() |
136 { | 137 { |
(...skipping 22 matching lines...) Expand all Loading... | |
159 } | 160 } |
160 | 161 |
161 WebInputElement* toWebInputElement(WebElement* webElement) | 162 WebInputElement* toWebInputElement(WebElement* webElement) |
162 { | 163 { |
163 if (!isHTMLInputElement(*webElement->unwrap<Element>())) | 164 if (!isHTMLInputElement(*webElement->unwrap<Element>())) |
164 return 0; | 165 return 0; |
165 | 166 |
166 return static_cast<WebInputElement*>(webElement); | 167 return static_cast<WebInputElement*>(webElement); |
167 } | 168 } |
168 } // namespace blink | 169 } // namespace blink |
OLD | NEW |