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

Side by Side Diff: chrome/browser/chromeos/login/app_launch_controller.cc

Issue 1412813003: This CL replaces user_manager::UserID with AccountId. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@468875--Chrome-OS-handles-deletion-of-Gmail-account-poorly--Create-AccountID-structure-part2--user_names
Patch Set: Fix Win GN build. Created 5 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/chromeos/login/app_launch_controller.h" 5 #include "chrome/browser/chromeos/login/app_launch_controller.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/json/json_file_value_serializer.h" 10 #include "base/json/json_file_value_serializer.h"
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 if (CrosSettings::Get()->GetBoolean( 315 if (CrosSettings::Get()->GetBoolean(
316 kAccountsPrefDeviceLocalAccountPromptForNetworkWhenOffline, 316 kAccountsPrefDeviceLocalAccountPromptForNetworkWhenOffline,
317 &should_prompt)) { 317 &should_prompt)) {
318 return should_prompt; 318 return should_prompt;
319 } 319 }
320 320
321 // Default to true to allow network configuration if the policy is missing. 321 // Default to true to allow network configuration if the policy is missing.
322 return true; 322 return true;
323 } 323 }
324 324
325 return !user_manager::UserManager::Get()->GetOwnerEmail().empty(); 325 return user_manager::UserManager::Get()->GetOwnerAccountId().is_valid();
326 } 326 }
327 327
328 bool AppLaunchController::NeedOwnerAuthToConfigureNetwork() { 328 bool AppLaunchController::NeedOwnerAuthToConfigureNetwork() {
329 if (need_owner_auth_to_configure_network_callback_) 329 if (need_owner_auth_to_configure_network_callback_)
330 return need_owner_auth_to_configure_network_callback_->Run(); 330 return need_owner_auth_to_configure_network_callback_->Run();
331 331
332 policy::BrowserPolicyConnectorChromeOS* connector = 332 policy::BrowserPolicyConnectorChromeOS* connector =
333 g_browser_process->platform_part()->browser_policy_connector_chromeos(); 333 g_browser_process->platform_part()->browser_policy_connector_chromeos();
334 return !connector->IsEnterpriseManaged(); 334 return !connector->IsEnterpriseManaged();
335 } 335 }
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
445 KioskAppLaunchError::Save(error); 445 KioskAppLaunchError::Save(error);
446 chrome::AttemptUserExit(); 446 chrome::AttemptUserExit();
447 CleanUp(); 447 CleanUp();
448 } 448 }
449 449
450 bool AppLaunchController::IsShowingNetworkConfigScreen() { 450 bool AppLaunchController::IsShowingNetworkConfigScreen() {
451 return network_config_requested_; 451 return network_config_requested_;
452 } 452 }
453 453
454 } // namespace chromeos 454 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698