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

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

Issue 22938005: Add ErrorConsole UI for Extension Install Warnings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@dc_ec_install_warnings
Patch Set: Requested UI Changes Created 7 years, 4 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 (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/extension_system.h" 5 #include "chrome/browser/extensions/extension_system.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 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 // initialized (see issue 40144). Now that bookmarks aren't imported and 214 // initialized (see issue 40144). Now that bookmarks aren't imported and
215 // the event routers need to be initialized for every profile individually, 215 // the event routers need to be initialized for every profile individually,
216 // initialize them with the extension service. 216 // initialize them with the extension service.
217 extension_service_->InitEventRouters(); 217 extension_service_->InitEventRouters();
218 218
219 extension_warning_service_.reset(new ExtensionWarningService(profile_)); 219 extension_warning_service_.reset(new ExtensionWarningService(profile_));
220 extension_warning_badge_service_.reset( 220 extension_warning_badge_service_.reset(
221 new ExtensionWarningBadgeService(profile_)); 221 new ExtensionWarningBadgeService(profile_));
222 extension_warning_service_->AddObserver( 222 extension_warning_service_->AddObserver(
223 extension_warning_badge_service_.get()); 223 extension_warning_badge_service_.get());
224 error_console_.reset(new ErrorConsole(profile_)); 224 error_console_.reset(new ErrorConsole(profile_, extension_service_.get()));
225 } 225 }
226 226
227 void ExtensionSystemImpl::Shared::Shutdown() { 227 void ExtensionSystemImpl::Shared::Shutdown() {
228 if (extension_warning_service_) { 228 if (extension_warning_service_) {
229 extension_warning_service_->RemoveObserver( 229 extension_warning_service_->RemoveObserver(
230 extension_warning_badge_service_.get()); 230 extension_warning_badge_service_.get());
231 } 231 }
232 if (extension_service_) 232 if (extension_service_)
233 extension_service_->Shutdown(); 233 extension_service_->Shutdown();
234 } 234 }
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts( 387 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts(
388 const std::string& extension_id, 388 const std::string& extension_id,
389 const extension_misc::UnloadedExtensionReason reason) { 389 const extension_misc::UnloadedExtensionReason reason) {
390 BrowserThread::PostTask( 390 BrowserThread::PostTask(
391 BrowserThread::IO, FROM_HERE, 391 BrowserThread::IO, FROM_HERE,
392 base::Bind(&ExtensionInfoMap::RemoveExtension, info_map(), 392 base::Bind(&ExtensionInfoMap::RemoveExtension, info_map(),
393 extension_id, reason)); 393 extension_id, reason));
394 } 394 }
395 395
396 } // namespace extensions 396 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698