OLD | NEW |
1 // Copyright (c) 2012 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_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ |
6 #define CHROME_BROWSER_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ | 6 #define CHROME_BROWSER_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/browser/autofill/autofill_external_delegate.h" | 9 #include "chrome/browser/autofill/autofill_external_delegate.h" |
10 | 10 |
11 class AutofillManager; | 11 class AutofillManager; |
12 class TabContents; | 12 class TabContents; |
13 typedef TabContents TabContentsWrapper; | |
14 | 13 |
15 // This test class is meant to give tests a base AutofillExternalDelegate | 14 // This test class is meant to give tests a base AutofillExternalDelegate |
16 // class that requires no additional work to compile with (i.e. all the | 15 // class that requires no additional work to compile with (i.e. all the |
17 // pure virtual functions have been giving empty methods). | 16 // pure virtual functions have been giving empty methods). |
18 class TestAutofillExternalDelegate : public AutofillExternalDelegate { | 17 class TestAutofillExternalDelegate : public AutofillExternalDelegate { |
19 public: | 18 public: |
20 TestAutofillExternalDelegate(TabContentsWrapper* wrapper, | 19 TestAutofillExternalDelegate(TabContents* tab_contents, |
21 AutofillManager* autofill_manager); | 20 AutofillManager* autofill_manager); |
22 virtual ~TestAutofillExternalDelegate(); | 21 virtual ~TestAutofillExternalDelegate(); |
23 | 22 |
24 virtual void ApplyAutofillSuggestions( | 23 virtual void ApplyAutofillSuggestions( |
25 const std::vector<string16>& autofill_values, | 24 const std::vector<string16>& autofill_values, |
26 const std::vector<string16>& autofill_labels, | 25 const std::vector<string16>& autofill_labels, |
27 const std::vector<string16>& autofill_icons, | 26 const std::vector<string16>& autofill_icons, |
28 const std::vector<int>& autofill_unique_ids) OVERRIDE; | 27 const std::vector<int>& autofill_unique_ids) OVERRIDE; |
29 | 28 |
30 virtual void OnQueryPlatformSpecific(int query_id, | 29 virtual void OnQueryPlatformSpecific(int query_id, |
31 const webkit::forms::FormData& form, | 30 const webkit::forms::FormData& form, |
32 const webkit::forms::FormField& field, | 31 const webkit::forms::FormField& field, |
33 const gfx::Rect& bounds) OVERRIDE; | 32 const gfx::Rect& bounds) OVERRIDE; |
34 | 33 |
35 | 34 |
36 virtual void HideAutofillPopupInternal() OVERRIDE; | 35 virtual void HideAutofillPopupInternal() OVERRIDE; |
37 | 36 |
38 virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; | 37 virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; |
39 | 38 |
40 private: | 39 private: |
41 DISALLOW_COPY_AND_ASSIGN(TestAutofillExternalDelegate); | 40 DISALLOW_COPY_AND_ASSIGN(TestAutofillExternalDelegate); |
42 }; | 41 }; |
43 | 42 |
44 #endif // CHROME_BROWSER_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ | 43 #endif // CHROME_BROWSER_AUTOFILL_TEST_AUTOFILL_EXTERNAL_DELEGATE_H_ |
OLD | NEW |