Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Unified Diff: components/autofill/browser/form_group.cc

Issue 17392006: In components/autofill, move browser/ to core/browser/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to fix conflicts Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/autofill/browser/form_group.h ('k') | components/autofill/browser/form_structure.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/autofill/browser/form_group.cc
diff --git a/components/autofill/browser/form_group.cc b/components/autofill/browser/form_group.cc
deleted file mode 100644
index 3b33dcbedd0e306b10c65fa6d9261003f57061cd..0000000000000000000000000000000000000000
--- a/components/autofill/browser/form_group.cc
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "components/autofill/browser/form_group.h"
-
-namespace autofill {
-
-void FormGroup::GetMatchingTypes(const base::string16& text,
- const std::string& app_locale,
- FieldTypeSet* matching_types) const {
- if (text.empty()) {
- matching_types->insert(EMPTY_TYPE);
- return;
- }
-
- FieldTypeSet types;
- GetSupportedTypes(&types);
- for (FieldTypeSet::const_iterator type = types.begin();
- type != types.end(); ++type) {
- // TODO(isherman): Matches are case-sensitive for now. Let's keep an eye on
- // this and decide whether there are compelling reasons to add case-
- // insensitivity.
- if (GetInfo(*type, app_locale) == text)
- matching_types->insert(*type);
- }
-}
-
-void FormGroup::GetNonEmptyTypes(const std::string& app_locale,
- FieldTypeSet* non_empty_types) const {
- FieldTypeSet types;
- GetSupportedTypes(&types);
- for (FieldTypeSet::const_iterator type = types.begin();
- type != types.end(); ++type) {
- if (!GetInfo(*type, app_locale).empty())
- non_empty_types->insert(*type);
- }
-}
-
-base::string16 FormGroup::GetInfo(AutofillFieldType type,
- const std::string& app_locale) const {
- return GetRawInfo(type);
-}
-
-bool FormGroup::SetInfo(AutofillFieldType type,
- const base::string16& value,
- const std::string& app_locale) {
- SetRawInfo(type, value);
- return true;
-}
-
-} // namespace autofill
« no previous file with comments | « components/autofill/browser/form_group.h ('k') | components/autofill/browser/form_structure.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698