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

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

Issue 2482173002: [ios] Adds OmahaServiceProvider. (Closed)
Patch Set: XML 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
« no previous file with comments | « ios/public/provider/chrome/browser/test_chrome_browser_provider.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "ios/public/provider/chrome/browser/test_chrome_browser_provider.h" 5 #include "ios/public/provider/chrome/browser/test_chrome_browser_provider.h"
6 6
7 #import <UIKit/UIKit.h> 7 #import <UIKit/UIKit.h>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/mac/scoped_nsobject.h" 10 #include "base/mac/scoped_nsobject.h"
11 #include "base/memory/ptr_util.h" 11 #include "base/memory/ptr_util.h"
12 #include "ios/public/provider/chrome/browser/distribution/test_app_distribution_ provider.h" 12 #include "ios/public/provider/chrome/browser/distribution/test_app_distribution_ provider.h"
13 #include "ios/public/provider/chrome/browser/omaha/omaha_service_provider.h"
13 #include "ios/public/provider/chrome/browser/signin/fake_chrome_identity_service .h" 14 #include "ios/public/provider/chrome/browser/signin/fake_chrome_identity_service .h"
14 #import "ios/public/provider/chrome/browser/test_updatable_resource_provider.h" 15 #import "ios/public/provider/chrome/browser/test_updatable_resource_provider.h"
15 #import "ios/public/provider/chrome/browser/voice/test_voice_search_provider.h" 16 #import "ios/public/provider/chrome/browser/voice/test_voice_search_provider.h"
16 #import "ios/public/provider/chrome/browser/voice/voice_search_language.h" 17 #import "ios/public/provider/chrome/browser/voice/voice_search_language.h"
17 18
18 @interface TestStyledTextField : UITextField<TextFieldStyling> 19 @interface TestStyledTextField : UITextField<TextFieldStyling>
19 @end 20 @end
20 21
21 @implementation TestStyledTextField 22 @implementation TestStyledTextField
22 @synthesize placeholderStyle = _placeholderStyle; 23 @synthesize placeholderStyle = _placeholderStyle;
23 @synthesize textValidator = _textValidator; 24 @synthesize textValidator = _textValidator;
24 25
25 - (void)setUseErrorStyling:(BOOL)error { 26 - (void)setUseErrorStyling:(BOOL)error {
26 } 27 }
27 @end 28 @end
28 29
29 namespace ios { 30 namespace ios {
30 31
31 TestChromeBrowserProvider::TestChromeBrowserProvider() 32 TestChromeBrowserProvider::TestChromeBrowserProvider()
32 : app_distribution_provider_( 33 : app_distribution_provider_(
33 base::MakeUnique<TestAppDistributionProvider>()), 34 base::MakeUnique<TestAppDistributionProvider>()),
35 omaha_service_provider_(base::MakeUnique<OmahaServiceProvider>()),
34 updatable_resource_provider_( 36 updatable_resource_provider_(
35 base::MakeUnique<TestUpdatableResourceProvider>()), 37 base::MakeUnique<TestUpdatableResourceProvider>()),
36 voice_search_provider_(base::MakeUnique<TestVoiceSearchProvider>()) {} 38 voice_search_provider_(base::MakeUnique<TestVoiceSearchProvider>()) {}
37 39
38 TestChromeBrowserProvider::~TestChromeBrowserProvider() {} 40 TestChromeBrowserProvider::~TestChromeBrowserProvider() {}
39 41
40 // static 42 // static
41 TestChromeBrowserProvider* TestChromeBrowserProvider::GetTestProvider() { 43 TestChromeBrowserProvider* TestChromeBrowserProvider::GetTestProvider() {
42 ChromeBrowserProvider* provider = GetChromeBrowserProvider(); 44 ChromeBrowserProvider* provider = GetChromeBrowserProvider();
43 DCHECK(provider); 45 DCHECK(provider);
(...skipping 28 matching lines...) Expand all
72 74
73 VoiceSearchProvider* TestChromeBrowserProvider::GetVoiceSearchProvider() const { 75 VoiceSearchProvider* TestChromeBrowserProvider::GetVoiceSearchProvider() const {
74 return voice_search_provider_.get(); 76 return voice_search_provider_.get();
75 } 77 }
76 78
77 AppDistributionProvider* TestChromeBrowserProvider::GetAppDistributionProvider() 79 AppDistributionProvider* TestChromeBrowserProvider::GetAppDistributionProvider()
78 const { 80 const {
79 return app_distribution_provider_.get(); 81 return app_distribution_provider_.get();
80 } 82 }
81 83
84 OmahaServiceProvider* TestChromeBrowserProvider::GetOmahaServiceProvider()
85 const {
86 return omaha_service_provider_.get();
87 }
88
82 } // namespace ios 89 } // namespace ios
OLDNEW
« no previous file with comments | « ios/public/provider/chrome/browser/test_chrome_browser_provider.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698