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

Side by Side Diff: components/autofill/core/common/autofill_util.h

Issue 2411333004: Make HasAutocompleteAttributeValue handle multi-valued strings (Closed)
Patch Set: Make HasAutocompleteAttributeValue handle multi-valued strings Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_ 5 #ifndef COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_
6 #define COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_ 6 #define COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <string>
11 #include <vector>
12
10 #include "base/strings/string16.h" 13 #include "base/strings/string16.h"
11 #include "components/autofill/core/common/form_field_data.h" 14 #include "components/autofill/core/common/form_field_data.h"
12 15
13 namespace autofill { 16 namespace autofill {
14 17
15 // Returns true when command line switch |kEnableSuggestionsWithSubstringMatch| 18 // Returns true when command line switch |kEnableSuggestionsWithSubstringMatch|
16 // is on. 19 // is on.
17 bool IsFeatureSubstringMatchEnabled(); 20 bool IsFeatureSubstringMatchEnabled();
18 21
19 // Returns true when keyboard accessory is enabled. 22 // Returns true when keyboard accessory is enabled.
(...skipping 24 matching lines...) Expand all
44 bool IsDesktopPlatform(); 47 bool IsDesktopPlatform();
45 48
46 bool ShouldSkipField(const FormFieldData& field); 49 bool ShouldSkipField(const FormFieldData& field);
47 50
48 bool IsCheckable(const FormFieldData::CheckStatus& check_status); 51 bool IsCheckable(const FormFieldData::CheckStatus& check_status);
49 bool IsChecked(const FormFieldData::CheckStatus& check_status); 52 bool IsChecked(const FormFieldData::CheckStatus& check_status);
50 void SetCheckStatus(FormFieldData* form_field_data, 53 void SetCheckStatus(FormFieldData* form_field_data,
51 bool isCheckable, 54 bool isCheckable,
52 bool isChecked); 55 bool isChecked);
53 56
57 // Lowercases and tokenizes a given |attribute| string.
58 // Considers any ASCII whitespace character as a possible separator.
59 // Also ignores empty tokens, resulting in a collapsing of whitespace.
60 std::vector<std::string> LowercaseAndTokenizeAttributeString(
61 const std::string& attribute);
62
54 } // namespace autofill 63 } // namespace autofill
55 64
56 #endif // COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_ 65 #endif // COMPONENTS_AUTOFILL_CORE_COMMON_AUTOFILL_UTIL_H_
OLDNEW
« no previous file with comments | « components/autofill/core/browser/form_structure.cc ('k') | components/autofill/core/common/autofill_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698