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

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

Issue 615083004: Use ThreadChecker rather than DCHECK_CURRENTLY_ON. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: DCHECK testing_profile Created 6 years, 2 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/extensions/extension_service.h" 5 #include "chrome/browser/extensions/extension_service.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <iterator> 8 #include <iterator>
9 #include <set> 9 #include <set>
10 10
(...skipping 1878 matching lines...) Expand 10 before | Expand all | Expand 10 after
1889 extension_sync_service_->SyncExtensionChangeIfNeeded(*extension); 1889 extension_sync_service_->SyncExtensionChangeIfNeeded(*extension);
1890 } 1890 }
1891 1891
1892 const Extension* ExtensionService::GetPendingExtensionUpdate( 1892 const Extension* ExtensionService::GetPendingExtensionUpdate(
1893 const std::string& id) const { 1893 const std::string& id) const {
1894 return delayed_installs_.GetByID(id); 1894 return delayed_installs_.GetByID(id);
1895 } 1895 }
1896 1896
1897 void ExtensionService::RegisterContentSettings( 1897 void ExtensionService::RegisterContentSettings(
1898 HostContentSettingsMap* host_content_settings_map) { 1898 HostContentSettingsMap* host_content_settings_map) {
1899 DCHECK_CURRENTLY_ON(BrowserThread::UI);
1899 host_content_settings_map->RegisterProvider( 1900 host_content_settings_map->RegisterProvider(
1900 HostContentSettingsMap::INTERNAL_EXTENSION_PROVIDER, 1901 HostContentSettingsMap::INTERNAL_EXTENSION_PROVIDER,
1901 scoped_ptr<content_settings::ObservableProvider>( 1902 scoped_ptr<content_settings::ObservableProvider>(
1902 new content_settings::InternalExtensionProvider(this))); 1903 new content_settings::InternalExtensionProvider(this)));
1903 1904
1904 host_content_settings_map->RegisterProvider( 1905 host_content_settings_map->RegisterProvider(
1905 HostContentSettingsMap::CUSTOM_EXTENSION_PROVIDER, 1906 HostContentSettingsMap::CUSTOM_EXTENSION_PROVIDER,
1906 scoped_ptr<content_settings::ObservableProvider>( 1907 scoped_ptr<content_settings::ObservableProvider>(
1907 new content_settings::CustomExtensionProvider( 1908 new content_settings::CustomExtensionProvider(
1908 extensions::ContentSettingsService::Get( 1909 extensions::ContentSettingsService::Get(
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after
2369 } 2370 }
2370 2371
2371 void ExtensionService::OnProfileDestructionStarted() { 2372 void ExtensionService::OnProfileDestructionStarted() {
2372 ExtensionIdSet ids_to_unload = registry_->enabled_extensions().GetIDs(); 2373 ExtensionIdSet ids_to_unload = registry_->enabled_extensions().GetIDs();
2373 for (ExtensionIdSet::iterator it = ids_to_unload.begin(); 2374 for (ExtensionIdSet::iterator it = ids_to_unload.begin();
2374 it != ids_to_unload.end(); 2375 it != ids_to_unload.end();
2375 ++it) { 2376 ++it) {
2376 UnloadExtension(*it, UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN); 2377 UnloadExtension(*it, UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN);
2377 } 2378 }
2378 } 2379 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698