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

Side by Side Diff: chrome/browser/chromeos/login/screens/eula_screen.cc

Issue 2705363002: cros: Move BaseScreenDelegate::ExitCodes into separate file, ScreenExitCode. (Closed)
Patch Set: Rebase Created 3 years, 9 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 (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/chromeos/login/screens/eula_screen.h" 5 #include "chrome/browser/chromeos/login/screens/eula_screen.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 view_->Show(); 91 view_->Show();
92 } 92 }
93 93
94 void EulaScreen::Hide() { 94 void EulaScreen::Hide() {
95 if (view_) 95 if (view_)
96 view_->Hide(); 96 view_->Hide();
97 } 97 }
98 98
99 void EulaScreen::OnUserAction(const std::string& action_id) { 99 void EulaScreen::OnUserAction(const std::string& action_id) {
100 if (action_id == kUserActionAcceptButtonClicked) 100 if (action_id == kUserActionAcceptButtonClicked)
101 Finish(BaseScreenDelegate::EULA_ACCEPTED); 101 Finish(ScreenExitCode::EULA_ACCEPTED);
102 else if (action_id == kUserActionBackButtonClicked) 102 else if (action_id == kUserActionBackButtonClicked)
103 Finish(BaseScreenDelegate::EULA_BACK); 103 Finish(ScreenExitCode::EULA_BACK);
104 else 104 else
105 BaseScreen::OnUserAction(action_id); 105 BaseScreen::OnUserAction(action_id);
106 } 106 }
107 107
108 void EulaScreen::OnContextKeyUpdated( 108 void EulaScreen::OnContextKeyUpdated(
109 const ::login::ScreenContext::KeyType& key) { 109 const ::login::ScreenContext::KeyType& key) {
110 if (key == kContextKeyUsageStatsEnabled && delegate_) { 110 if (key == kContextKeyUsageStatsEnabled && delegate_) {
111 delegate_->SetUsageStatisticsReporting( 111 delegate_->SetUsageStatisticsReporting(
112 context_.GetBoolean(kContextKeyUsageStatsEnabled)); 112 context_.GetBoolean(kContextKeyUsageStatsEnabled));
113 } 113 }
114 } 114 }
115 115
116 void EulaScreen::OnPasswordFetched(const std::string& tpm_password) { 116 void EulaScreen::OnPasswordFetched(const std::string& tpm_password) {
117 tpm_password_ = tpm_password; 117 tpm_password_ = tpm_password;
118 if (view_) 118 if (view_)
119 view_->OnPasswordFetched(tpm_password_); 119 view_->OnPasswordFetched(tpm_password_);
120 } 120 }
121 121
122 } // namespace chromeos 122 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698