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

Side by Side Diff: chrome/browser/extensions/extension_prefs.h

Issue 17038002: Separate the NTP app ordering from the app list app ordering (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: change from notification to observer 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 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/memory/linked_ptr.h" 12 #include "base/memory/linked_ptr.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "base/time/time.h" 14 #include "base/time/time.h"
15 #include "base/values.h" 15 #include "base/values.h"
16 #include "chrome/browser/extensions/blacklist.h" 16 #include "chrome/browser/extensions/blacklist.h"
17 #include "chrome/browser/extensions/extension_scoped_prefs.h" 17 #include "chrome/browser/extensions/extension_scoped_prefs.h"
18 #include "chrome/browser/prefs/scoped_user_pref_update.h" 18 #include "chrome/browser/prefs/scoped_user_pref_update.h"
19 #include "chrome/browser/ui/app_list/app_list_extension_sorting.h"
19 #include "chrome/common/extensions/extension.h" 20 #include "chrome/common/extensions/extension.h"
20 #include "components/browser_context_keyed_service/browser_context_keyed_service .h" 21 #include "components/browser_context_keyed_service/browser_context_keyed_service .h"
21 #include "extensions/common/url_pattern_set.h" 22 #include "extensions/common/url_pattern_set.h"
22 #include "sync/api/string_ordinal.h" 23 #include "sync/api/string_ordinal.h"
23 24
24 class ExtensionPrefValueMap; 25 class ExtensionPrefValueMap;
25 class ExtensionSorting; 26 class ExtensionSorting;
26 class PrefService; 27 class PrefService;
27 class Profile; 28 class Profile;
28 29
(...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after
477 } 478 }
478 479
479 // The underlying PrefService. 480 // The underlying PrefService.
480 PrefService* pref_service() const { return prefs_; } 481 PrefService* pref_service() const { return prefs_; }
481 482
482 // The underlying ExtensionSorting. 483 // The underlying ExtensionSorting.
483 ExtensionSorting* extension_sorting() const { 484 ExtensionSorting* extension_sorting() const {
484 return extension_sorting_.get(); 485 return extension_sorting_.get();
485 } 486 }
486 487
488 // The ordering of apps in the app list.
489 AppListExtensionSorting* app_list_extension_sorting() const {
490 return app_list_extension_sorting_.get();
491 }
492
487 // Describes the URLs that are able to install extensions. See 493 // Describes the URLs that are able to install extensions. See
488 // prefs::kExtensionAllowedInstallSites for more information. 494 // prefs::kExtensionAllowedInstallSites for more information.
489 URLPatternSet GetAllowedInstallSites(); 495 URLPatternSet GetAllowedInstallSites();
490 496
491 // Schedules garbage collection of an extension's on-disk data on the next 497 // Schedules garbage collection of an extension's on-disk data on the next
492 // start of this ExtensionService. Applies only to extensions with isolated 498 // start of this ExtensionService. Applies only to extensions with isolated
493 // storage. 499 // storage.
494 void SetNeedsStorageGarbageCollection(bool value); 500 void SetNeedsStorageGarbageCollection(bool value);
495 bool NeedsStorageGarbageCollection(); 501 bool NeedsStorageGarbageCollection();
496 502
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 // Base extensions install directory. 616 // Base extensions install directory.
611 base::FilePath install_directory_; 617 base::FilePath install_directory_;
612 618
613 // Weak pointer, owned by Profile. 619 // Weak pointer, owned by Profile.
614 ExtensionPrefValueMap* extension_pref_value_map_; 620 ExtensionPrefValueMap* extension_pref_value_map_;
615 621
616 // Contains all the logic for handling the order for various extension 622 // Contains all the logic for handling the order for various extension
617 // properties. 623 // properties.
618 scoped_ptr<ExtensionSorting> extension_sorting_; 624 scoped_ptr<ExtensionSorting> extension_sorting_;
619 625
626 scoped_ptr<AppListExtensionSorting> app_list_extension_sorting_;
627
620 scoped_refptr<ContentSettingsStore> content_settings_store_; 628 scoped_refptr<ContentSettingsStore> content_settings_store_;
621 629
622 scoped_ptr<TimeProvider> time_provider_; 630 scoped_ptr<TimeProvider> time_provider_;
623 631
624 bool extensions_disabled_; 632 bool extensions_disabled_;
625 633
626 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); 634 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs);
627 }; 635 };
628 636
629 } // namespace extensions 637 } // namespace extensions
630 638
631 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ 639 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698