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

Side by Side Diff: ios/public/provider/chrome/browser/test_chrome_browser_provider.h

Issue 2505953002: [ios] Adds test provider implementations. (Closed)
Patch Set: Fix build file. Created 4 years, 1 month 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 IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_ 5 #ifndef IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_
6 #define IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_ 6 #define IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h" 11 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h"
12 #include "ios/public/provider/chrome/browser/ui/text_field_styling.h" 12 #include "ios/public/provider/chrome/browser/ui/text_field_styling.h"
13 13
14 namespace ios { 14 namespace ios {
15 15
16 class TestChromeBrowserProvider : public ChromeBrowserProvider { 16 class TestChromeBrowserProvider : public ChromeBrowserProvider {
17 public: 17 public:
18 TestChromeBrowserProvider(); 18 TestChromeBrowserProvider();
19 ~TestChromeBrowserProvider() override; 19 ~TestChromeBrowserProvider() override;
20 20
21 // Returns the current provider as a |TestChromeBrowserProvider|. 21 // Returns the current provider as a |TestChromeBrowserProvider|.
22 static TestChromeBrowserProvider* GetTestProvider(); 22 static TestChromeBrowserProvider* GetTestProvider();
23 23
24 // ChromeBrowserProvider: 24 // ChromeBrowserProvider:
25 InfoBarViewPlaceholder CreateInfoBarView(
26 CGRect frame,
27 InfoBarViewDelegate* delegate) override NS_RETURNS_RETAINED;
25 SigninResourcesProvider* GetSigninResourcesProvider() override; 28 SigninResourcesProvider* GetSigninResourcesProvider() override;
26 void SetChromeIdentityServiceForTesting( 29 void SetChromeIdentityServiceForTesting(
27 std::unique_ptr<ChromeIdentityService> service) override; 30 std::unique_ptr<ChromeIdentityService> service) override;
28 ChromeIdentityService* GetChromeIdentityService() override; 31 ChromeIdentityService* GetChromeIdentityService() override;
32 LiveTabContextProvider* GetLiveTabContextProvider() override;
29 UITextField<TextFieldStyling>* CreateStyledTextField( 33 UITextField<TextFieldStyling>* CreateStyledTextField(
30 CGRect frame) const override NS_RETURNS_RETAINED; 34 CGRect frame) const override NS_RETURNS_RETAINED;
31 NSArray* GetAvailableVoiceSearchLanguages() const override; 35 NSArray* GetAvailableVoiceSearchLanguages() const override;
32 VoiceSearchProvider* GetVoiceSearchProvider() const override; 36 VoiceSearchProvider* GetVoiceSearchProvider() const override;
33 AppDistributionProvider* GetAppDistributionProvider() const override; 37 AppDistributionProvider* GetAppDistributionProvider() const override;
34 OmahaServiceProvider* GetOmahaServiceProvider() const override; 38 OmahaServiceProvider* GetOmahaServiceProvider() const override;
39 std::unique_ptr<sync_sessions::SyncedWindowDelegatesGetter>
40 CreateSyncedWindowDelegatesGetter(
41 ios::ChromeBrowserState* browser_state) override;
35 id<NativeAppWhitelistManager> GetNativeAppWhitelistManager() const override; 42 id<NativeAppWhitelistManager> GetNativeAppWhitelistManager() const override;
36 43
37 private: 44 private:
38 std::unique_ptr<AppDistributionProvider> app_distribution_provider_; 45 std::unique_ptr<AppDistributionProvider> app_distribution_provider_;
39 std::unique_ptr<ChromeIdentityService> chrome_identity_service_; 46 std::unique_ptr<ChromeIdentityService> chrome_identity_service_;
47 std::unique_ptr<LiveTabContextProvider> live_tab_context_provider_;
40 std::unique_ptr<OmahaServiceProvider> omaha_service_provider_; 48 std::unique_ptr<OmahaServiceProvider> omaha_service_provider_;
41 std::unique_ptr<SigninResourcesProvider> signin_resources_provider_; 49 std::unique_ptr<SigninResourcesProvider> signin_resources_provider_;
42 std::unique_ptr<VoiceSearchProvider> voice_search_provider_; 50 std::unique_ptr<VoiceSearchProvider> voice_search_provider_;
43 51
44 DISALLOW_COPY_AND_ASSIGN(TestChromeBrowserProvider); 52 DISALLOW_COPY_AND_ASSIGN(TestChromeBrowserProvider);
45 }; 53 };
46 54
47 } // namespace ios 55 } // namespace ios
48 56
49 #endif // IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_ 57 #endif // IOS_PUBLIC_PROVIDER_CHROME_BROWSER_TEST_CHROME_BROWSER_PROVIDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698