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

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

Issue 1129293002: Fix the System Profile with extensions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove autogenerated actions Created 5 years, 7 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/extension_system_impl.h" 5 #include "chrome/browser/extensions/extension_system_impl.h"
6 6
7 #include "base/base_switches.h" 7 #include "base/base_switches.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
299 navigation_observer_.reset(new NavigationObserver(profile_)); 299 navigation_observer_.reset(new NavigationObserver(profile_));
300 300
301 bool allow_noisy_errors = !command_line->HasSwitch(switches::kNoErrorDialogs); 301 bool allow_noisy_errors = !command_line->HasSwitch(switches::kNoErrorDialogs);
302 ExtensionErrorReporter::Init(allow_noisy_errors); 302 ExtensionErrorReporter::Init(allow_noisy_errors);
303 303
304 shared_user_script_master_.reset(new SharedUserScriptMaster(profile_)); 304 shared_user_script_master_.reset(new SharedUserScriptMaster(profile_));
305 305
306 // ExtensionService depends on RuntimeData. 306 // ExtensionService depends on RuntimeData.
307 runtime_data_.reset(new RuntimeData(ExtensionRegistry::Get(profile_))); 307 runtime_data_.reset(new RuntimeData(ExtensionRegistry::Get(profile_)));
308 308
309 bool autoupdate_enabled = !profile_->IsGuestSession(); 309 bool autoupdate_enabled = !profile_->IsGuestSession() &&
310 !profile_->IsSystemProfile();
310 #if defined(OS_CHROMEOS) 311 #if defined(OS_CHROMEOS)
311 if (!extensions_enabled) 312 if (!extensions_enabled)
312 autoupdate_enabled = false; 313 autoupdate_enabled = false;
313 #endif // defined(OS_CHROMEOS) 314 #endif // defined(OS_CHROMEOS)
314 extension_service_.reset(new ExtensionService( 315 extension_service_.reset(new ExtensionService(
315 profile_, base::CommandLine::ForCurrentProcess(), 316 profile_, base::CommandLine::ForCurrentProcess(),
316 profile_->GetPath().AppendASCII(extensions::kInstallDirectoryName), 317 profile_->GetPath().AppendASCII(extensions::kInstallDirectoryName),
317 ExtensionPrefs::Get(profile_), Blacklist::Get(profile_), 318 ExtensionPrefs::Get(profile_), Blacklist::Get(profile_),
318 autoupdate_enabled, extensions_enabled, &ready_)); 319 autoupdate_enabled, extensions_enabled, &ready_));
319 320
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
551 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts( 552 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts(
552 const std::string& extension_id, 553 const std::string& extension_id,
553 const UnloadedExtensionInfo::Reason reason) { 554 const UnloadedExtensionInfo::Reason reason) {
554 BrowserThread::PostTask( 555 BrowserThread::PostTask(
555 BrowserThread::IO, 556 BrowserThread::IO,
556 FROM_HERE, 557 FROM_HERE,
557 base::Bind(&InfoMap::RemoveExtension, info_map(), extension_id, reason)); 558 base::Bind(&InfoMap::RemoveExtension, info_map(), extension_id, reason));
558 } 559 }
559 560
560 } // namespace extensions 561 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/chrome_process_manager_delegate.cc ('k') | chrome/browser/extensions/tab_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698