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

Side by Side Diff: components/autofill/core/browser/credit_card_field.h

Issue 1859453002: components/autofill: scoped_ptr -> unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments addressed Created 4 years, 8 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_BROWSER_CREDIT_CARD_FIELD_H_ 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_CREDIT_CARD_FIELD_H_
6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_CREDIT_CARD_FIELD_H_ 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_CREDIT_CARD_FIELD_H_
7 7
8 #include <memory>
8 #include <vector> 9 #include <vector>
9 10
10 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
11 #include "base/macros.h" 12 #include "base/macros.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "components/autofill/core/browser/autofill_type.h" 13 #include "components/autofill/core/browser/autofill_type.h"
14 #include "components/autofill/core/browser/form_field.h" 14 #include "components/autofill/core/browser/form_field.h"
15 15
16 namespace autofill { 16 namespace autofill {
17 17
18 class AutofillField; 18 class AutofillField;
19 class AutofillScanner; 19 class AutofillScanner;
20 20
21 class CreditCardField : public FormField { 21 class CreditCardField : public FormField {
22 public: 22 public:
23 ~CreditCardField() override; 23 ~CreditCardField() override;
24 static scoped_ptr<FormField> Parse(AutofillScanner* scanner); 24 static std::unique_ptr<FormField> Parse(AutofillScanner* scanner);
25 25
26 protected: 26 protected:
27 void AddClassifications(FieldCandidatesMap* field_candidates) const override; 27 void AddClassifications(FieldCandidatesMap* field_candidates) const override;
28 28
29 private: 29 private:
30 friend class CreditCardFieldTest; 30 friend class CreditCardFieldTest;
31 31
32 // Returns true if |scanner| points to a field that looks like a month 32 // Returns true if |scanner| points to a field that looks like a month
33 // <select>. 33 // <select>.
34 static bool LikelyCardMonthSelectField(AutofillScanner* scanner); 34 static bool LikelyCardMonthSelectField(AutofillScanner* scanner);
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 // |CREDIT_CARD_EXP_DATE_2_DIGIT_YEAR|; otherwise we store 90 // |CREDIT_CARD_EXP_DATE_2_DIGIT_YEAR|; otherwise we store
91 // |CREDIT_CARD_EXP_DATE_4_DIGIT_YEAR|. 91 // |CREDIT_CARD_EXP_DATE_4_DIGIT_YEAR|.
92 ServerFieldType exp_year_type_; 92 ServerFieldType exp_year_type_;
93 93
94 DISALLOW_COPY_AND_ASSIGN(CreditCardField); 94 DISALLOW_COPY_AND_ASSIGN(CreditCardField);
95 }; 95 };
96 96
97 } // namespace autofill 97 } // namespace autofill
98 98
99 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_CREDIT_CARD_FIELD_H_ 99 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_CREDIT_CARD_FIELD_H_
OLDNEW
« no previous file with comments | « components/autofill/core/browser/country_names.cc ('k') | components/autofill/core/browser/credit_card_field.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698