-
tkent@chromium.org authored
Reviewed by Darin Adler. Refactor HTMLInputElement: Move createRender(), appendFormData(), saveFormControlState() and restoreFormControlState() to InputTypes. https://bugs.webkit.org/show_bug.cgi?id=47834 This change adds BaseButtonInputType and BaseCheckableInputType. They are super classes of some concrete InputType classes. No new tests. Just a code refactoring. * CMakeLists.txt: Add BaseButtonInputType and BaseCheckableInputType files. * GNUmakefile.am: ditto. * WebCore.gypi: ditto. * WebCore.pro: ditto. * WebCore.vcproj/WebCore.vcproj: ditto. * WebCore.xcodeproj/project.pbxproj: ditto. * html/BaseButtonInputType.cpp: Added. (WebCore::BaseButtonInputType::appendFormData): (WebCore::BaseButtonInputType::createRenderer): * html/BaseButtonInputType.h: Added. (WebCore::BaseButtonInputType::BaseButtonInputType): * html/BaseCheckableInputType.cpp: Added. (WebCore::BaseCheckableInputType::saveFormControlState): (WebCore::BaseCheckableInputType::restoreFormControlState): (WebCore::BaseCheckableInputType::appendFormData): * html/BaseCheckableInputType.h: Added. (WebCore::BaseCheckableInputType::BaseCheckableInputType): * html/ButtonInputType.h: Change the super class. (WebCore::ButtonInputType::ButtonInputType): * html/CheckboxInputType.h: Change the super class. (WebCore::CheckboxInputType::CheckboxInputType): * html/FileInputType.cpp: (WebCore::FileInputType::appendFormData): (WebCore::FileInputType::createRenderer): * html/FileInputType.h: Change the super class. (WebCore::FileInputType::FileInputType): * html/HTMLFormControlElement.h: Make placeholderShouldBeVisible() public for access from TextFieldInputType. * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::saveFormControlState): (WebCore::HTMLInputElement::restoreFormControlState): (WebCore::HTMLInputElement::createRenderer): (WebCore::HTMLInputElement::appendFormData): * html/HTMLInputElement.h: Add the following functions for ImageInputType and SubmitInputType. (WebCore::HTMLInputElement::xPosition): (WebCore::HTMLInputElement::yPosition): * html/HiddenInputType.cpp: (WebCore::HiddenInputType::createRenderer): * html/HiddenInputType.h: * html/ImageInputType.cpp: (WebCore::ImageInputType::isFormDataAppendable): (WebCore::ImageInputType::appendFormData): (WebCore::ImageInputType::createRenderer): * html/ImageInputType.h: Change the super class. (WebCore::ImageInputType::ImageInputType): * html/InputType.cpp: (WebCore::InputType::saveFormControlState): (WebCore::InputType::restoreFormControlState): (WebCore::InputType::isFormDataAppendable): (WebCore::InputType::appendFormData): (WebCore::InputType::createRenderer): * html/InputType.h: * html/PasswordInputType.cpp: (WebCore::PasswordInputType::saveFormControlState): (WebCore::PasswordInputType::restoreFormControlState): * html/PasswordInputType.h: * html/RadioInputType.h: Change the super class. (WebCore::RadioInputType::RadioInputType): * html/RangeInputType.cpp: (WebCore::RangeInputType::createRenderer): * html/RangeInputType.h: * html/ResetInputType.h: (WebCore::ResetInputType::ResetInputType): * html/SubmitInputType.cpp: (WebCore::SubmitInputType::appendFormData): * html/SubmitInputType.h: Change the super class. (WebCore::SubmitInputType::SubmitInputType): * html/TextFieldInputType.cpp: (WebCore::TextFieldInputType::createRenderer): * html/TextFieldInputType.h: git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70511 268f45cc-cd09-0410-ab3c-d52691b4dbfc
61684f1a