From 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 27 Jun 2017 06:07:23 +0000 Subject: webkitgtk-2.16.5 --- Source/WebCore/html/FormController.h | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) (limited to 'Source/WebCore/html/FormController.h') diff --git a/Source/WebCore/html/FormController.h b/Source/WebCore/html/FormController.h index e146b64f6..92ad0e672 100644 --- a/Source/WebCore/html/FormController.h +++ b/Source/WebCore/html/FormController.h @@ -19,10 +19,9 @@ * */ -#ifndef FormController_h -#define FormController_h +#pragma once -#include "CheckedRadioButtons.h" +#include "RadioButtonGroups.h" #include #include #include @@ -74,13 +73,10 @@ inline void FormControlState::append(const String& value) class FormController { WTF_MAKE_FAST_ALLOCATED; public: - static OwnPtr create() - { - return adoptPtr(new FormController); - } + FormController(); ~FormController(); - CheckedRadioButtons& checkedRadioButtons() { return m_checkedRadioButtons; } + RadioButtonGroups& radioButtonGroups() { return m_radioButtonGroups; } void registerFormElementWithState(HTMLFormControlElementWithState*); void unregisterFormElementWithState(HTMLFormControlElementWithState*); @@ -95,22 +91,20 @@ public: void restoreControlStateFor(HTMLFormControlElementWithState&); void restoreControlStateIn(HTMLFormElement&); - static Vector getReferencedFilePaths(const Vector& stateVector); + WEBCORE_EXPORT static Vector getReferencedFilePaths(const Vector& stateVector); private: - typedef ListHashSet, 64> FormElementListHashSet; - typedef HashMap, OwnPtr> SavedFormStateMap; + typedef ListHashSet> FormElementListHashSet; + typedef HashMap, std::unique_ptr> SavedFormStateMap; - FormController(); - static OwnPtr createSavedFormStateMap(const FormElementListHashSet&); + static std::unique_ptr createSavedFormStateMap(const FormElementListHashSet&); FormControlState takeStateForFormElement(const HTMLFormControlElementWithState&); static void formStatesFromStateVector(const Vector&, SavedFormStateMap&); - CheckedRadioButtons m_checkedRadioButtons; + RadioButtonGroups m_radioButtonGroups; FormElementListHashSet m_formElementsWithState; SavedFormStateMap m_savedFormStateMap; - OwnPtr m_formKeyGenerator; + std::unique_ptr m_formKeyGenerator; }; } // namespace WebCore -#endif -- cgit v1.2.1