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

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc

Issue 539273002: Added UI to enable debugging features on CrOS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 #include "chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.h" 5 #include "chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
(...skipping 615 matching lines...) Expand 10 before | Expand all | Expand 10 after
626 626
627 if (gaia_silent_load_) { 627 if (gaia_silent_load_) {
628 // The variable is assigned to false because silently loaded Gaia page was 628 // The variable is assigned to false because silently loaded Gaia page was
629 // used. 629 // used.
630 gaia_silent_load_ = false; 630 gaia_silent_load_ = false;
631 if (focus_stolen_) 631 if (focus_stolen_)
632 HandleGaiaUIReady(); 632 HandleGaiaUIReady();
633 } 633 }
634 signin_screen_handler_->UpdateState(ErrorScreenActor::ERROR_REASON_UPDATE); 634 signin_screen_handler_->UpdateState(ErrorScreenActor::ERROR_REASON_UPDATE);
635 635
636 PrefService* prefs = g_browser_process->local_state(); 636 if (core_oobe_actor_) {
637 if (prefs->GetBoolean(prefs::kFactoryResetRequested)) { 637 PrefService* prefs = g_browser_process->local_state();
638 if (core_oobe_actor_) 638 if (prefs->GetBoolean(prefs::kFactoryResetRequested)) {
639 core_oobe_actor_->ShowDeviceResetScreen(); 639 core_oobe_actor_->ShowDeviceResetScreen();
640 } else if (prefs->GetBoolean(prefs::kDebuggingFeaturesRequested)) {
641 core_oobe_actor_->ShowEnableDebuggingScreen();
642 }
640 } 643 }
641 } 644 }
642 645
643 void GaiaScreenHandler::MaybePreloadAuthExtension() { 646 void GaiaScreenHandler::MaybePreloadAuthExtension() {
644 VLOG(1) << "MaybePreloadAuthExtension() call."; 647 VLOG(1) << "MaybePreloadAuthExtension() call.";
645 648
646 // If cookies clearing was initiated or |dns_clear_task_running_| then auth 649 // If cookies clearing was initiated or |dns_clear_task_running_| then auth
647 // extension showing has already been initiated and preloading is senseless. 650 // extension showing has already been initiated and preloading is senseless.
648 if (signin_screen_handler_->ShouldLoadGaia() && 651 if (signin_screen_handler_->ShouldLoadGaia() &&
649 !gaia_silent_load_ && 652 !gaia_silent_load_ &&
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
689 692
690 SigninScreenHandlerDelegate* GaiaScreenHandler::Delegate() { 693 SigninScreenHandlerDelegate* GaiaScreenHandler::Delegate() {
691 DCHECK(signin_screen_handler_); 694 DCHECK(signin_screen_handler_);
692 return signin_screen_handler_->delegate_; 695 return signin_screen_handler_->delegate_;
693 } 696 }
694 697
695 void GaiaScreenHandler::SetSigninScreenHandler(SigninScreenHandler* handler) { 698 void GaiaScreenHandler::SetSigninScreenHandler(SigninScreenHandler* handler) {
696 signin_screen_handler_ = handler; 699 signin_screen_handler_ = handler;
697 } 700 }
698 } // namespace chromeos 701 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698