summaryrefslogtreecommitdiffstats
path: root/webkit/glue/form_field.cc
diff options
context:
space:
mode:
authortony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-10 03:59:11 +0000
committertony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-10 03:59:11 +0000
commita151aa05cb2beecdb9f92a108ff78fa11ea9ce2e (patch)
treea58db79ec08d6fc45827106bc9aa2c5e2434ac52 /webkit/glue/form_field.cc
parent56aaac0fa20bf3033f12f71a920431db1c7f0cc5 (diff)
downloadchromium_src-a151aa05cb2beecdb9f92a108ff78fa11ea9ce2e.zip
chromium_src-a151aa05cb2beecdb9f92a108ff78fa11ea9ce2e.tar.gz
chromium_src-a151aa05cb2beecdb9f92a108ff78fa11ea9ce2e.tar.bz2
Revert "Move conditions of FormFields creation to FormFieldHistoryManager;
AutoFill does not have the same conditions. This required manipulating the FormField data structure to add necessary field data." This reverts commit r38570. TBR=jhawkins Review URL: http://codereview.chromium.org/602014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38573 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/form_field.cc')
-rw-r--r--webkit/glue/form_field.cc28
1 files changed, 4 insertions, 24 deletions
diff --git a/webkit/glue/form_field.cc b/webkit/glue/form_field.cc
index 4d95cb8..a87644f 100644
--- a/webkit/glue/form_field.cc
+++ b/webkit/glue/form_field.cc
@@ -4,39 +4,19 @@
#include "webkit/glue/form_field.h"
-#include "base/string_util.h"
-
-using WebKit::WebInputElement;
-
namespace webkit_glue {
FormField::FormField() {
}
-FormField::FormField(const WebInputElement& input_element) {
- name_ = input_element.nameForAutofill();
-
- // TODO(jhawkins): Extract the field label. For now we just use the field
- // name.
- label_ = name_;
-
- value_ = input_element.value();
- TrimWhitespace(value_, TRIM_LEADING, &value_);
-
- form_control_type_ = input_element.formControlType();
- input_type_ = input_element.inputType();
-}
-
FormField::FormField(const string16& label,
const string16& name,
- const string16& value,
- const string16& form_control_type,
- WebInputElement::InputType input_type)
+ const string16& html_input_type,
+ const string16& value)
: label_(label),
name_(name),
- value_(value),
- form_control_type_(form_control_type),
- input_type_(input_type) {
+ html_input_type_(html_input_type),
+ value_(value) {
}
} // namespace webkit_glue