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

Side by Side Diff: chrome/browser/chromeos/arc/arc_support_host.cc

Issue 2137713002: arc: Provide progress to load TOS content for OptIn. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "chrome/browser/chromeos/arc/arc_support_host.h" 5 #include "chrome/browser/chromeos/arc/arc_support_host.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "ash/common/system/chromeos/devicetype_utils.h" 9 #include "ash/common/system/chromeos/devicetype_utils.h"
10 #include "base/i18n/timezone.h" 10 #include "base/i18n/timezone.h"
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_PROGRESS_ANDROID)); 131 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_PROGRESS_ANDROID));
132 loadtime_data->SetString( 132 loadtime_data->SetString(
133 "authorizationFailed", 133 "authorizationFailed",
134 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_AUTHORIZATION_FAILED)); 134 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_AUTHORIZATION_FAILED));
135 loadtime_data->SetString( 135 loadtime_data->SetString(
136 "termsOfService", 136 "termsOfService",
137 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_TERMS_OF_SERVICE)); 137 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_TERMS_OF_SERVICE));
138 loadtime_data->SetString( 138 loadtime_data->SetString(
139 "textBackupRestore", 139 "textBackupRestore",
140 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_BACKUP_RESTORE)); 140 l10n_util::GetStringUTF16(IDS_ARC_OPT_IN_DIALOG_BACKUP_RESTORE));
141 loadtime_data->SetString(
142 "serverError",
143 l10n_util::GetStringUTF16(IDS_ARC_SERVER_COMMUNICATION_ERROR));
141 144
142 const std::string& app_locale = g_browser_process->GetApplicationLocale(); 145 const std::string& app_locale = g_browser_process->GetApplicationLocale();
143 const std::string& country_code = base::CountryCodeForCurrentTimezone(); 146 const std::string& country_code = base::CountryCodeForCurrentTimezone();
144 loadtime_data->SetString("countryCode", country_code); 147 loadtime_data->SetString("countryCode", country_code);
145 148
146 arc::ArcAuthService* arc_auth_service = arc::ArcAuthService::Get(); 149 arc::ArcAuthService* arc_auth_service = arc::ArcAuthService::Get();
147 150
148 loadtime_data->SetBoolean(kBackupRestoreEnabled, 151 loadtime_data->SetBoolean(kBackupRestoreEnabled,
149 arc_auth_service->profile()->GetPrefs()->GetBoolean( 152 arc_auth_service->profile()->GetPrefs()->GetBoolean(
150 prefs::kArcBackupRestoreEnabled)); 153 prefs::kArcBackupRestoreEnabled));
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 EnableBackupRestore(is_enabled); 283 EnableBackupRestore(is_enabled);
281 } else { 284 } else {
282 NOTREACHED(); 285 NOTREACHED();
283 } 286 }
284 } 287 }
285 288
286 scoped_refptr<base::SingleThreadTaskRunner> ArcSupportHost::task_runner() 289 scoped_refptr<base::SingleThreadTaskRunner> ArcSupportHost::task_runner()
287 const { 290 const {
288 return base::ThreadTaskRunnerHandle::Get(); 291 return base::ThreadTaskRunnerHandle::Get();
289 } 292 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698