Changeset 89194 in webkit
- Timestamp:
- Jun 18, 2011 11:50:53 AM (13 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r89191 r89194 1 2011-06-18 Sam Weinig <sam@webkit.org> 2 3 Reviewed by Darin Adler. 4 5 REGRESSION (r63854-63958): placeholder not shown for number inputs 6 https://bugs.webkit.org/show_bug.cgi?id=61095 7 8 Refactor HTMLInputElement supportsPlaceholder support to delegate to the 9 InputType. Make BaseTextInputType and NumberInputType return true, matching 10 the current HTML5 spec. 11 12 * html/BaseTextInputType.cpp: 13 (WebCore::BaseTextInputType::supportsPlaceholder): 14 * html/BaseTextInputType.h: 15 Add override implementation of supportsPlaceholder that returns true. 16 17 * html/HTMLInputElement.cpp: 18 (WebCore::HTMLInputElement::supportsPlaceholder): 19 Delegate to the InputType. 20 21 * html/InputType.cpp: 22 (WebCore::InputType::supportsPlaceholder): 23 * html/InputType.h: 24 Add base implementation of supportsPlaceholder that returns false. 25 26 * html/NumberInputType.cpp: 27 (WebCore::NumberInputType::supportsPlaceholder): 28 * html/NumberInputType.h: 29 Add override implementation of supportsPlaceholder that returns true. 30 1 31 2011-06-18 Sheriff Bot <webkit.review.bot@gmail.com> 2 32 -
trunk/Source/WebCore/html/BaseTextInputType.cpp
r86292 r89194 51 51 } 52 52 53 bool BaseTextInputType::supportsPlaceholder() const 54 { 55 return true; 56 } 57 53 58 } // namespace WebCore -
trunk/Source/WebCore/html/BaseTextInputType.h
r74895 r89194 45 45 virtual bool isTextType() const; 46 46 virtual bool patternMismatch(const String&) const; 47 virtual bool supportsPlaceholder() const; 47 48 }; 48 49 -
trunk/Source/WebCore/html/HTMLInputElement.cpp
r88627 r89194 1804 1804 bool HTMLInputElement::supportsPlaceholder() const 1805 1805 { 1806 return isTextType();1806 return m_inputType->supportsPlaceholder(); 1807 1807 } 1808 1808 -
trunk/Source/WebCore/html/InputType.cpp
r87371 r89194 650 650 } 651 651 652 bool InputType::supportsPlaceholder() const 653 { 654 return false; 655 } 656 652 657 namespace InputTypeNames { 653 658 -
trunk/Source/WebCore/html/InputType.h
r87881 r89194 223 223 virtual bool isSteppable() const; 224 224 virtual bool shouldRespectHeightAndWidthAttributes(); 225 virtual bool supportsPlaceholder() const; 225 226 226 227 // Parses the specified string for the type, and return -
trunk/Source/WebCore/html/NumberInputType.cpp
r87371 r89194 265 265 } 266 266 267 bool NumberInputType::supportsPlaceholder() const 268 { 269 return true; 270 } 271 267 272 bool NumberInputType::isNumberField() const 268 273 { -
trunk/Source/WebCore/html/NumberInputType.h
r87371 r89194 71 71 virtual bool hasUnacceptableValue(); 72 72 virtual bool shouldRespectSpeechAttribute(); 73 virtual bool supportsPlaceholder() const; 73 74 virtual bool isNumberField() const; 74 75 };
Note: See TracChangeset
for help on using the changeset viewer.