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
3 // found in the LICENSE file.
5 #include "chrome/browser/android/mock_google_location_settings_helper.h"
7 bool MockGoogleLocationSettingsHelper::master_location_enabled
= false;
8 bool MockGoogleLocationSettingsHelper::google_apps_location_enabled
= false;
9 bool MockGoogleLocationSettingsHelper::was_google_location_settings_called
13 GoogleLocationSettingsHelper
* GoogleLocationSettingsHelper::Create() {
14 return new MockGoogleLocationSettingsHelper();
17 MockGoogleLocationSettingsHelper::MockGoogleLocationSettingsHelper()
18 : GoogleLocationSettingsHelper() {
21 MockGoogleLocationSettingsHelper::~MockGoogleLocationSettingsHelper() {
24 void MockGoogleLocationSettingsHelper::SetLocationStatus(
25 bool master
, bool google_apps
) {
26 master_location_enabled
= master
;
27 google_apps_location_enabled
= google_apps
;
30 std::string
MockGoogleLocationSettingsHelper::GetAcceptButtonLabel() {
31 return google_apps_location_enabled
? "Allow" : "Settings";
34 void MockGoogleLocationSettingsHelper::ShowGoogleLocationSettings() {
35 was_google_location_settings_called
= true;
38 bool MockGoogleLocationSettingsHelper::IsGoogleAppsLocationSettingEnabled() {
39 return google_apps_location_enabled
;
42 bool MockGoogleLocationSettingsHelper::IsMasterLocationSettingEnabled() {
43 return master_location_enabled
;
46 bool MockGoogleLocationSettingsHelper::WasGoogleLocationSettingsCalled() {
47 return was_google_location_settings_called
;