OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
11 #include "chrome/browser/autofill/personal_data_manager_observer.h" | 11 #include "chrome/browser/autofill/personal_data_manager_observer.h" |
12 #include "chrome/browser/ui/webui/options/options_ui.h" | 12 #include "chrome/browser/ui/webui/options/options_ui.h" |
13 | 13 |
14 class PersonalDataManager; | 14 class PersonalDataManager; |
15 | 15 |
16 namespace base { | 16 namespace base { |
17 class DictionaryValue; | 17 class DictionaryValue; |
18 class ListValue; | 18 class ListValue; |
19 } | 19 } |
20 | 20 |
21 class AutofillOptionsHandler : public OptionsPageUIHandler, | 21 class AutofillOptionsHandler : public OptionsPageUIHandler, |
22 public PersonalDataManagerObserver { | 22 public PersonalDataManagerObserver { |
23 public: | 23 public: |
24 AutofillOptionsHandler(); | 24 AutofillOptionsHandler(); |
25 virtual ~AutofillOptionsHandler(); | 25 virtual ~AutofillOptionsHandler(); |
26 | 26 |
27 // OptionsPageUIHandler implementation. | 27 // OptionsPageUIHandler implementation. |
28 virtual void GetLocalizedValues( | 28 virtual void GetLocalizedValues( |
29 base::DictionaryValue* localized_strings) OVERRIDE; | 29 base::DictionaryValue* localized_strings) OVERRIDE; |
30 virtual void Initialize() OVERRIDE; | 30 virtual void InitializeHandler() OVERRIDE; |
31 virtual void RegisterMessages() OVERRIDE; | 31 virtual void RegisterMessages() OVERRIDE; |
32 | 32 |
33 // PersonalDataManagerObserver implementation. | 33 // PersonalDataManagerObserver implementation. |
34 virtual void OnPersonalDataChanged() OVERRIDE; | 34 virtual void OnPersonalDataChanged() OVERRIDE; |
35 | 35 |
36 private: | 36 private: |
37 // Loads the strings for the address and credit card overlays. | 37 // Loads the strings for the address and credit card overlays. |
38 void SetAddressOverlayStrings(base::DictionaryValue* localized_strings); | 38 void SetAddressOverlayStrings(base::DictionaryValue* localized_strings); |
39 void SetCreditCardOverlayStrings(base::DictionaryValue* localized_strings); | 39 void SetCreditCardOverlayStrings(base::DictionaryValue* localized_strings); |
40 | 40 |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 void ValidatePhoneNumbers(const base::ListValue* args); | 80 void ValidatePhoneNumbers(const base::ListValue* args); |
81 | 81 |
82 // The personal data manager, used to load Autofill profiles and credit cards. | 82 // The personal data manager, used to load Autofill profiles and credit cards. |
83 // Unowned pointer, may not be NULL. | 83 // Unowned pointer, may not be NULL. |
84 PersonalDataManager* personal_data_; | 84 PersonalDataManager* personal_data_; |
85 | 85 |
86 DISALLOW_COPY_AND_ASSIGN(AutofillOptionsHandler); | 86 DISALLOW_COPY_AND_ASSIGN(AutofillOptionsHandler); |
87 }; | 87 }; |
88 | 88 |
89 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ | 89 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_AUTOFILL_OPTIONS_HANDLER_H_ |
OLD | NEW |