| OLD | NEW |
| 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/login/screens/arc_terms_of_service_screen.h" | 5 #include "chrome/browser/chromeos/login/screens/arc_terms_of_service_screen.h" |
| 6 | 6 |
| 7 #include "chrome/browser/chromeos/login/screens/base_screen_delegate.h" | 7 #include "chrome/browser/chromeos/login/screens/base_screen_delegate.h" |
| 8 #include "chrome/browser/chromeos/login/wizard_controller.h" | 8 #include "chrome/browser/chromeos/login/wizard_controller.h" |
| 9 #include "chrome/browser/metrics/metrics_reporting_state.h" | 9 #include "chrome/browser/metrics/metrics_reporting_state.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 DCHECK(actor_); | 21 DCHECK(actor_); |
| 22 if (actor_) | 22 if (actor_) |
| 23 actor_->SetDelegate(this); | 23 actor_->SetDelegate(this); |
| 24 } | 24 } |
| 25 | 25 |
| 26 ArcTermsOfServiceScreen::~ArcTermsOfServiceScreen() { | 26 ArcTermsOfServiceScreen::~ArcTermsOfServiceScreen() { |
| 27 if (actor_) | 27 if (actor_) |
| 28 actor_->SetDelegate(nullptr); | 28 actor_->SetDelegate(nullptr); |
| 29 } | 29 } |
| 30 | 30 |
| 31 void ArcTermsOfServiceScreen::PrepareToShow() {} | |
| 32 | |
| 33 void ArcTermsOfServiceScreen::Show() { | 31 void ArcTermsOfServiceScreen::Show() { |
| 34 if (!actor_) | 32 if (!actor_) |
| 35 return; | 33 return; |
| 36 | 34 |
| 37 // Show the screen. | 35 // Show the screen. |
| 38 actor_->Show(); | 36 actor_->Show(); |
| 39 } | 37 } |
| 40 | 38 |
| 41 void ArcTermsOfServiceScreen::Hide() { | 39 void ArcTermsOfServiceScreen::Hide() { |
| 42 if (actor_) | 40 if (actor_) |
| (...skipping 20 matching lines...) Expand all Loading... |
| 63 Finish(BaseScreenDelegate::ARC_TERMS_OF_SERVICE_FINISHED); | 61 Finish(BaseScreenDelegate::ARC_TERMS_OF_SERVICE_FINISHED); |
| 64 } | 62 } |
| 65 | 63 |
| 66 void ArcTermsOfServiceScreen::OnActorDestroyed( | 64 void ArcTermsOfServiceScreen::OnActorDestroyed( |
| 67 ArcTermsOfServiceScreenActor* actor) { | 65 ArcTermsOfServiceScreenActor* actor) { |
| 68 DCHECK_EQ(actor, actor_); | 66 DCHECK_EQ(actor, actor_); |
| 69 actor_ = nullptr; | 67 actor_ = nullptr; |
| 70 } | 68 } |
| 71 | 69 |
| 72 } // namespace chromeos | 70 } // namespace chromeos |
| OLD | NEW |