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

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

Issue 2920253003: kiosk: Tighten cert manager UI (Closed)
Patch Set: rebase, base test is removed :( Created 3 years, 6 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/policy/proto/chrome_device_policy.proto » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 return can_configure_network_callback_->Run(); 354 return can_configure_network_callback_->Run();
355 355
356 if (IsEnterpriseManaged()) { 356 if (IsEnterpriseManaged()) {
357 bool should_prompt; 357 bool should_prompt;
358 if (CrosSettings::Get()->GetBoolean( 358 if (CrosSettings::Get()->GetBoolean(
359 kAccountsPrefDeviceLocalAccountPromptForNetworkWhenOffline, 359 kAccountsPrefDeviceLocalAccountPromptForNetworkWhenOffline,
360 &should_prompt)) { 360 &should_prompt)) {
361 return should_prompt; 361 return should_prompt;
362 } 362 }
363 363
364 // Default to true to allow network configuration if the policy is missing. 364 // Network configuration has to be explicitly allowed by the policy.
365 return true; 365 // Default to false if the policy is missing.
366 return false;
366 } 367 }
367 368
368 return user_manager::UserManager::Get()->GetOwnerAccountId().is_valid(); 369 return user_manager::UserManager::Get()->GetOwnerAccountId().is_valid();
369 } 370 }
370 371
371 bool AppLaunchController::NeedOwnerAuthToConfigureNetwork() { 372 bool AppLaunchController::NeedOwnerAuthToConfigureNetwork() {
372 if (need_owner_auth_to_configure_network_callback_) 373 if (need_owner_auth_to_configure_network_callback_)
373 return need_owner_auth_to_configure_network_callback_->Run(); 374 return need_owner_auth_to_configure_network_callback_->Run();
374 375
375 return !IsEnterpriseManaged(); 376 return !IsEnterpriseManaged();
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
512 KioskAppLaunchError::Save(error); 513 KioskAppLaunchError::Save(error);
513 chrome::AttemptUserExit(); 514 chrome::AttemptUserExit();
514 CleanUp(); 515 CleanUp();
515 } 516 }
516 517
517 bool AppLaunchController::IsShowingNetworkConfigScreen() { 518 bool AppLaunchController::IsShowingNetworkConfigScreen() {
518 return network_config_requested_; 519 return network_config_requested_;
519 } 520 }
520 521
521 } // namespace chromeos 522 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/policy/proto/chrome_device_policy.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698