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

Side by Side Diff: trunk/src/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc

Issue 14642018: Revert 197960 "[chromeos] Remove dependencies of StatisticsProvi..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 7 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 | Annotate | Revision Log
OLDNEW
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 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" 5 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "ash/ash_switches.h" 9 #include "ash/ash_switches.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 23 matching lines...) Expand all
34 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" 34 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h"
35 #include "chrome/browser/ui/webui/chromeos/login/terms_of_service_screen_handler .h" 35 #include "chrome/browser/ui/webui/chromeos/login/terms_of_service_screen_handler .h"
36 #include "chrome/browser/ui/webui/chromeos/login/update_screen_handler.h" 36 #include "chrome/browser/ui/webui/chromeos/login/update_screen_handler.h"
37 #include "chrome/browser/ui/webui/chromeos/login/user_image_screen_handler.h" 37 #include "chrome/browser/ui/webui/chromeos/login/user_image_screen_handler.h"
38 #include "chrome/browser/ui/webui/chromeos/login/wrong_hwid_screen_handler.h" 38 #include "chrome/browser/ui/webui/chromeos/login/wrong_hwid_screen_handler.h"
39 #include "chrome/browser/ui/webui/options/chromeos/user_image_source.h" 39 #include "chrome/browser/ui/webui/options/chromeos/user_image_source.h"
40 #include "chrome/browser/ui/webui/theme_source.h" 40 #include "chrome/browser/ui/webui/theme_source.h"
41 #include "chrome/common/chrome_constants.h" 41 #include "chrome/common/chrome_constants.h"
42 #include "chrome/common/chrome_switches.h" 42 #include "chrome/common/chrome_switches.h"
43 #include "chrome/common/url_constants.h" 43 #include "chrome/common/url_constants.h"
44 #include "chromeos/chromeos_constants.h"
45 #include "content/public/browser/web_ui.h" 44 #include "content/public/browser/web_ui.h"
46 #include "content/public/browser/web_ui_data_source.h" 45 #include "content/public/browser/web_ui_data_source.h"
47 #include "grit/browser_resources.h" 46 #include "grit/browser_resources.h"
48 #include "ui/base/resource/resource_bundle.h" 47 #include "ui/base/resource/resource_bundle.h"
49 #include "ui/webui/web_ui_util.h" 48 #include "ui/webui/web_ui_util.h"
50 49
51 namespace chromeos { 50 namespace chromeos {
52 51
53 namespace { 52 namespace {
54 53
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 if (!UserManager::Get()->IsUserLoggedIn()) 338 if (!UserManager::Get()->IsUserLoggedIn())
340 localized_strings->SetString("screenType", "login"); 339 localized_strings->SetString("screenType", "login");
341 else 340 else
342 localized_strings->SetString("screenType", "login-add-user"); 341 localized_strings->SetString("screenType", "login-add-user");
343 } else { 342 } else {
344 localized_strings->SetString("screenType", "lock"); 343 localized_strings->SetString("screenType", "lock");
345 } 344 }
346 345
347 bool keyboard_driven_oobe = false; 346 bool keyboard_driven_oobe = false;
348 system::StatisticsProvider::GetInstance()->GetMachineFlag( 347 system::StatisticsProvider::GetInstance()->GetMachineFlag(
349 chromeos::kOemKeyboardDrivenOobeKey, &keyboard_driven_oobe); 348 chrome::kOemKeyboardDrivenOobeKey, &keyboard_driven_oobe);
350 localized_strings->SetString("highlightStrength", 349 localized_strings->SetString("highlightStrength",
351 keyboard_driven_oobe ? "strong" : "normal"); 350 keyboard_driven_oobe ? "strong" : "normal");
352 } 351 }
353 352
354 void OobeUI::InitializeScreenMaps() { 353 void OobeUI::InitializeScreenMaps() {
355 screen_names_.resize(SCREEN_UNKNOWN); 354 screen_names_.resize(SCREEN_UNKNOWN);
356 screen_names_[SCREEN_OOBE_NETWORK] = kScreenOobeNetwork; 355 screen_names_[SCREEN_OOBE_NETWORK] = kScreenOobeNetwork;
357 screen_names_[SCREEN_OOBE_EULA] = kScreenOobeEula; 356 screen_names_[SCREEN_OOBE_EULA] = kScreenOobeEula;
358 screen_names_[SCREEN_OOBE_UPDATE] = kScreenOobeUpdate; 357 screen_names_[SCREEN_OOBE_UPDATE] = kScreenOobeUpdate;
359 screen_names_[SCREEN_OOBE_ENROLLMENT] = kScreenOobeEnrollment; 358 screen_names_[SCREEN_OOBE_ENROLLMENT] = kScreenOobeEnrollment;
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 void OobeUI::OnCurrentScreenChanged(const std::string& screen) { 423 void OobeUI::OnCurrentScreenChanged(const std::string& screen) {
425 if (screen_ids_.count(screen)) { 424 if (screen_ids_.count(screen)) {
426 current_screen_ = screen_ids_[screen]; 425 current_screen_ = screen_ids_[screen];
427 } else { 426 } else {
428 NOTREACHED() << "Screen should be registered in InitializeScreenMaps()"; 427 NOTREACHED() << "Screen should be registered in InitializeScreenMaps()";
429 current_screen_ = SCREEN_UNKNOWN; 428 current_screen_ = SCREEN_UNKNOWN;
430 } 429 }
431 } 430 }
432 431
433 } // namespace chromeos 432 } // namespace chromeos
OLDNEW
« no previous file with comments | « trunk/src/chrome/browser/ui/webui/chromeos/login/core_oobe_handler.cc ('k') | trunk/src/chrome/chrome_browser_chromeos.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698