OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_AUTOCOMPLETE_HISTORY_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_AUTOCOMPLETE_HISTORY_MANAGER_H_ |
6 #define CHROME_BROWSER_AUTOCOMPLETE_HISTORY_MANAGER_H_ | 6 #define CHROME_BROWSER_AUTOCOMPLETE_HISTORY_MANAGER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 int query_id, | 42 int query_id, |
43 const string16& name, | 43 const string16& name, |
44 const string16& prefix, | 44 const string16& prefix, |
45 const std::vector<string16>& autofill_values, | 45 const std::vector<string16>& autofill_values, |
46 const std::vector<string16>& autofill_labels, | 46 const std::vector<string16>& autofill_labels, |
47 const std::vector<string16>& autofill_icons, | 47 const std::vector<string16>& autofill_icons, |
48 const std::vector<int>& autofill_unique_ids); | 48 const std::vector<int>& autofill_unique_ids); |
49 void OnFormSubmitted(const webkit_glue::FormData& form); | 49 void OnFormSubmitted(const webkit_glue::FormData& form); |
50 | 50 |
51 // Sets our external delegate. | 51 // Sets our external delegate. |
52 void SetExternalDelegate(AutofillExternalDelegate* delegate) { | 52 void SetExternalDelegate(AutofillExternalDelegate* delegate); |
53 external_delegate_ = delegate; | |
54 } | |
55 | 53 |
56 protected: | 54 protected: |
57 friend class AutocompleteHistoryManagerTest; | 55 friend class AutocompleteHistoryManagerTest; |
58 friend class AutofillManagerTest; | 56 friend class AutofillManagerTest; |
59 FRIEND_TEST_ALL_PREFIXES(AutocompleteHistoryManagerTest, ExternalDelegate); | 57 FRIEND_TEST_ALL_PREFIXES(AutocompleteHistoryManagerTest, ExternalDelegate); |
60 FRIEND_TEST_ALL_PREFIXES(AutofillManagerTest, TestTabContents); | 58 FRIEND_TEST_ALL_PREFIXES(AutofillManagerTest, TestTabContents); |
61 | 59 |
62 // For tests. | 60 // For tests. |
63 AutocompleteHistoryManager(TabContents* tab_contents, | 61 AutocompleteHistoryManager(TabContents* tab_contents, |
64 Profile* profile, | 62 Profile* profile, |
(...skipping 26 matching lines...) Expand all Loading... |
91 std::vector<int> autofill_unique_ids_; | 89 std::vector<int> autofill_unique_ids_; |
92 | 90 |
93 // Delegate to perform external processing (display, selection) on | 91 // Delegate to perform external processing (display, selection) on |
94 // our behalf. Weak. | 92 // our behalf. Weak. |
95 AutofillExternalDelegate* external_delegate_; | 93 AutofillExternalDelegate* external_delegate_; |
96 | 94 |
97 DISALLOW_COPY_AND_ASSIGN(AutocompleteHistoryManager); | 95 DISALLOW_COPY_AND_ASSIGN(AutocompleteHistoryManager); |
98 }; | 96 }; |
99 | 97 |
100 #endif // CHROME_BROWSER_AUTOCOMPLETE_HISTORY_MANAGER_H_ | 98 #endif // CHROME_BROWSER_AUTOCOMPLETE_HISTORY_MANAGER_H_ |
OLD | NEW |