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

Side by Side Diff: chrome/browser/extensions/external_provider_impl.cc

Issue 316863002: Rename "managed (mode|user)" to "supervised user" (part 1) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 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 | Annotate | Revision Log
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/extensions/external_provider_impl.h" 5 #include "chrome/browser/extensions/external_provider_impl.h"
6 6
7 #include <set> 7 #include <set>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 411 matching lines...) Expand 10 before | Expand all | Expand 10 after
422 #if defined(OS_CHROMEOS) 422 #if defined(OS_CHROMEOS)
423 chromeos::UserManager* user_manager = chromeos::UserManager::Get(); 423 chromeos::UserManager* user_manager = chromeos::UserManager::Get();
424 is_chromeos_demo_session = 424 is_chromeos_demo_session =
425 user_manager && user_manager->IsLoggedInAsDemoUser() && 425 user_manager && user_manager->IsLoggedInAsDemoUser() &&
426 connector->GetDeviceMode() == policy::DEVICE_MODE_RETAIL_KIOSK; 426 connector->GetDeviceMode() == policy::DEVICE_MODE_RETAIL_KIOSK;
427 bundled_extension_creation_flags = Extension::FROM_WEBSTORE | 427 bundled_extension_creation_flags = Extension::FROM_WEBSTORE |
428 Extension::WAS_INSTALLED_BY_DEFAULT; 428 Extension::WAS_INSTALLED_BY_DEFAULT;
429 #endif 429 #endif
430 430
431 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) 431 #if defined(OS_LINUX) && !defined(OS_CHROMEOS)
432 if (!profile->IsManaged()) { 432 if (!profile->IsSupervised()) {
433 provider_list->push_back( 433 provider_list->push_back(
434 linked_ptr<ExternalProviderInterface>( 434 linked_ptr<ExternalProviderInterface>(
435 new ExternalProviderImpl( 435 new ExternalProviderImpl(
436 service, 436 service,
437 new ExternalPrefLoader( 437 new ExternalPrefLoader(
438 chrome::DIR_STANDALONE_EXTERNAL_EXTENSIONS, 438 chrome::DIR_STANDALONE_EXTERNAL_EXTENSIONS,
439 ExternalPrefLoader::NONE), 439 ExternalPrefLoader::NONE),
440 profile, 440 profile,
441 Manifest::EXTERNAL_PREF, 441 Manifest::EXTERNAL_PREF,
442 Manifest::EXTERNAL_PREF_DOWNLOAD, 442 Manifest::EXTERNAL_PREF_DOWNLOAD,
443 bundled_extension_creation_flags))); 443 bundled_extension_creation_flags)));
444 } 444 }
445 #endif 445 #endif
446 446
447 #if defined(OS_CHROMEOS) 447 #if defined(OS_CHROMEOS)
448 if (!is_chromeos_demo_session && !is_chrome_os_public_session) { 448 if (!is_chromeos_demo_session && !is_chrome_os_public_session) {
449 int external_apps_path_id = profile->IsManaged() ? 449 int external_apps_path_id = profile->IsSupervised() ?
450 chrome::DIR_MANAGED_USERS_DEFAULT_APPS : 450 chrome::DIR_SUPERVISED_USERS_DEFAULT_APPS :
451 chrome::DIR_STANDALONE_EXTERNAL_EXTENSIONS; 451 chrome::DIR_STANDALONE_EXTERNAL_EXTENSIONS;
452 provider_list->push_back( 452 provider_list->push_back(
453 linked_ptr<ExternalProviderInterface>(new ExternalProviderImpl( 453 linked_ptr<ExternalProviderInterface>(new ExternalProviderImpl(
454 service, 454 service,
455 new ExternalPrefLoader(external_apps_path_id, 455 new ExternalPrefLoader(external_apps_path_id,
456 ExternalPrefLoader::NONE), 456 ExternalPrefLoader::NONE),
457 profile, 457 profile,
458 Manifest::EXTERNAL_PREF, 458 Manifest::EXTERNAL_PREF,
459 Manifest::EXTERNAL_PREF_DOWNLOAD, 459 Manifest::EXTERNAL_PREF_DOWNLOAD,
460 bundled_extension_creation_flags))); 460 bundled_extension_creation_flags)));
(...skipping 20 matching lines...) Expand all
481 new ExternalProviderImpl( 481 new ExternalProviderImpl(
482 service, 482 service,
483 app_pack_updater->CreateExternalLoader(), 483 app_pack_updater->CreateExternalLoader(),
484 profile, 484 profile,
485 Manifest::EXTERNAL_PREF, 485 Manifest::EXTERNAL_PREF,
486 Manifest::INVALID_LOCATION, 486 Manifest::INVALID_LOCATION,
487 Extension::NO_FLAGS))); 487 Extension::NO_FLAGS)));
488 } 488 }
489 #endif 489 #endif
490 490
491 if (!profile->IsManaged() && !is_chromeos_demo_session) { 491 if (!profile->IsSupervised() && !is_chromeos_demo_session) {
492 #if !defined(OS_WIN) 492 #if !defined(OS_WIN)
493 provider_list->push_back( 493 provider_list->push_back(
494 linked_ptr<ExternalProviderInterface>( 494 linked_ptr<ExternalProviderInterface>(
495 new ExternalProviderImpl( 495 new ExternalProviderImpl(
496 service, 496 service,
497 new ExternalPrefLoader(chrome::DIR_EXTERNAL_EXTENSIONS, 497 new ExternalPrefLoader(chrome::DIR_EXTERNAL_EXTENSIONS,
498 check_admin_permissions_on_mac), 498 check_admin_permissions_on_mac),
499 profile, 499 profile,
500 Manifest::EXTERNAL_PREF, 500 Manifest::EXTERNAL_PREF,
501 Manifest::EXTERNAL_PREF_DOWNLOAD, 501 Manifest::EXTERNAL_PREF_DOWNLOAD,
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
550 service, 550 service,
551 new ExternalComponentLoader(profile), 551 new ExternalComponentLoader(profile),
552 profile, 552 profile,
553 Manifest::INVALID_LOCATION, 553 Manifest::INVALID_LOCATION,
554 Manifest::EXTERNAL_COMPONENT, 554 Manifest::EXTERNAL_COMPONENT,
555 Extension::FROM_WEBSTORE | Extension::WAS_INSTALLED_BY_DEFAULT))); 555 Extension::FROM_WEBSTORE | Extension::WAS_INSTALLED_BY_DEFAULT)));
556 } 556 }
557 } 557 }
558 558
559 } // namespace extensions 559 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698