| OLD | NEW |
| 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/existing_user_controller.h" | 5 #include "chrome/browser/chromeos/login/existing_user_controller.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 void RecordPasswordChangeFlow(LoginPasswordChangeFlow flow) { | 177 void RecordPasswordChangeFlow(LoginPasswordChangeFlow flow) { |
| 178 UMA_HISTOGRAM_ENUMERATION("Login.PasswordChangeFlow", flow, | 178 UMA_HISTOGRAM_ENUMERATION("Login.PasswordChangeFlow", flow, |
| 179 LOGIN_PASSWORD_CHANGE_FLOW_COUNT); | 179 LOGIN_PASSWORD_CHANGE_FLOW_COUNT); |
| 180 } | 180 } |
| 181 | 181 |
| 182 bool ShouldForceDircrypto(const AccountId& account_id) { | 182 bool ShouldForceDircrypto(const AccountId& account_id) { |
| 183 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 183 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 184 chromeos::switches::kDisableEncryptionMigration)) { | 184 chromeos::switches::kDisableEncryptionMigration)) { |
| 185 return false; | 185 return false; |
| 186 } | 186 } |
| 187 |
| 188 chromeos::StartupUtils::SetExt4MigrationForArcAllowed(); |
| 189 |
| 187 // If the device is not officially supported to run ARC, we don't need to | 190 // If the device is not officially supported to run ARC, we don't need to |
| 188 // force Ext4 dircrypto. | 191 // force Ext4 dircrypto. |
| 189 if (!arc::IsArcAvailable()) | 192 if (!arc::IsArcAvailable()) |
| 190 return false; | 193 return false; |
| 191 | 194 |
| 192 // In some login flows (e.g. when siging in supervised user), ARC can not | 195 // In some login flows (e.g. when siging in supervised user), ARC can not |
| 193 // start. For such cases, we don't need to force Ext4 dircrypto. | 196 // start. For such cases, we don't need to force Ext4 dircrypto. |
| 194 chromeos::UserFlow* user_flow = | 197 chromeos::UserFlow* user_flow = |
| 195 chromeos::ChromeUserManager::Get()->GetUserFlow(account_id); | 198 chromeos::ChromeUserManager::Get()->GetUserFlow(account_id); |
| 196 if (!user_flow || !user_flow->CanStartArc()) | 199 if (!user_flow || !user_flow->CanStartArc()) |
| (...skipping 1296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1493 login_display_->ShowUnrecoverableCrypthomeErrorDialog(); | 1496 login_display_->ShowUnrecoverableCrypthomeErrorDialog(); |
| 1494 } | 1497 } |
| 1495 | 1498 |
| 1496 void ExistingUserController::ClearRecordedNames() { | 1499 void ExistingUserController::ClearRecordedNames() { |
| 1497 display_email_.clear(); | 1500 display_email_.clear(); |
| 1498 display_name_.clear(); | 1501 display_name_.clear(); |
| 1499 given_name_.clear(); | 1502 given_name_.clear(); |
| 1500 } | 1503 } |
| 1501 | 1504 |
| 1502 } // namespace chromeos | 1505 } // namespace chromeos |
| OLD | NEW |