Disable view source for Developer Tools.
[chromium-blink-merge.git] / chrome / browser / chromeos / login / screens / reset_screen.cc
blobeb0ecb55315b138d535713da1265480dbb434907
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/chromeos/login/screens/reset_screen.h"
7 #include "base/logging.h"
8 #include "chrome/browser/chromeos/customization_document.h"
9 #include "chrome/browser/chromeos/login/screens/screen_observer.h"
10 #include "chrome/browser/chromeos/login/wizard_controller.h"
12 namespace chromeos {
14 ResetScreen::ResetScreen(ScreenObserver* observer, ResetScreenActor* actor)
15 : WizardScreen(observer), actor_(actor) {
16 DCHECK(actor_);
17 if (actor_)
18 actor_->SetDelegate(this);
21 ResetScreen::~ResetScreen() {
22 if (actor_)
23 actor_->SetDelegate(NULL);
26 void ResetScreen::PrepareToShow() {
27 if (actor_)
28 actor_->PrepareToShow();
31 void ResetScreen::Show() {
32 if (actor_)
33 actor_->Show();
36 void ResetScreen::Hide() {
37 if (actor_)
38 actor_->Hide();
41 std::string ResetScreen::GetName() const {
42 return WizardController::kResetScreenName;
45 void ResetScreen::OnExit() {
46 get_screen_observer()->OnExit(ScreenObserver::RESET_CANCELED);
49 void ResetScreen::OnActorDestroyed(ResetScreenActor* actor) {
50 if (actor_ == actor)
51 actor_ = NULL;
54 } // namespace chromeos