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

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

Issue 7189029: Implement an initial extension settings API. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Add missing files Created 9 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <set> 8 #include <set>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after
484 return false; 484 return false;
485 } 485 }
486 486
487 return true; 487 return true;
488 } 488 }
489 489
490 ExtensionService::ExtensionService(Profile* profile, 490 ExtensionService::ExtensionService(Profile* profile,
491 const CommandLine* command_line, 491 const CommandLine* command_line,
492 const FilePath& install_directory, 492 const FilePath& install_directory,
493 ExtensionPrefs* extension_prefs, 493 ExtensionPrefs* extension_prefs,
494 ExtensionSettings* extension_settings,
494 bool autoupdate_enabled, 495 bool autoupdate_enabled,
495 bool extensions_enabled) 496 bool extensions_enabled)
496 : weak_ptr_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), 497 : weak_ptr_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)),
497 method_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), 498 method_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)),
498 profile_(profile), 499 profile_(profile),
499 extension_prefs_(extension_prefs), 500 extension_prefs_(extension_prefs),
501 extension_settings_(extension_settings),
500 pending_extension_manager_(*ALLOW_THIS_IN_INITIALIZER_LIST(this)), 502 pending_extension_manager_(*ALLOW_THIS_IN_INITIALIZER_LIST(this)),
501 install_directory_(install_directory), 503 install_directory_(install_directory),
502 extensions_enabled_(extensions_enabled), 504 extensions_enabled_(extensions_enabled),
503 show_extensions_prompts_(true), 505 show_extensions_prompts_(true),
504 ready_(false), 506 ready_(false),
505 toolbar_model_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), 507 toolbar_model_(ALLOW_THIS_IN_INITIALIZER_LIST(this)),
506 apps_promo_(profile->GetPrefs()), 508 apps_promo_(profile->GetPrefs()),
507 event_routers_initialized_(false) { 509 event_routers_initialized_(false) {
508 CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 510 CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
509 511
(...skipping 850 matching lines...) Expand 10 before | Expand all | Expand 10 after
1360 } 1362 }
1361 1363
1362 Profile* ExtensionService::profile() { 1364 Profile* ExtensionService::profile() {
1363 return profile_; 1365 return profile_;
1364 } 1366 }
1365 1367
1366 ExtensionPrefs* ExtensionService::extension_prefs() { 1368 ExtensionPrefs* ExtensionService::extension_prefs() {
1367 return extension_prefs_; 1369 return extension_prefs_;
1368 } 1370 }
1369 1371
1372 ExtensionSettings* ExtensionService::extension_settings() {
1373 return extension_settings_;
1374 }
1375
1370 ExtensionContentSettingsStore* 1376 ExtensionContentSettingsStore*
1371 ExtensionService::GetExtensionContentSettingsStore() { 1377 ExtensionService::GetExtensionContentSettingsStore() {
1372 return extension_prefs()->content_settings_store(); 1378 return extension_prefs()->content_settings_store();
1373 } 1379 }
1374 1380
1375 ExtensionUpdater* ExtensionService::updater() { 1381 ExtensionUpdater* ExtensionService::updater() {
1376 return updater_.get(); 1382 return updater_.get();
1377 } 1383 }
1378 1384
1379 void ExtensionService::CheckAdminBlacklist() { 1385 void ExtensionService::CheckAdminBlacklist() {
(...skipping 951 matching lines...) Expand 10 before | Expand all | Expand 10 after
2331 2337
2332 ExtensionService::NaClModuleInfoList::iterator 2338 ExtensionService::NaClModuleInfoList::iterator
2333 ExtensionService::FindNaClModule(const GURL& url) { 2339 ExtensionService::FindNaClModule(const GURL& url) {
2334 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin(); 2340 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin();
2335 iter != nacl_module_list_.end(); ++iter) { 2341 iter != nacl_module_list_.end(); ++iter) {
2336 if (iter->url == url) 2342 if (iter->url == url)
2337 return iter; 2343 return iter;
2338 } 2344 }
2339 return nacl_module_list_.end(); 2345 return nacl_module_list_.end();
2340 } 2346 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698