OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER_H_ | 5 #ifndef CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER_H_ |
6 #define CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER_H_ | 6 #define CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER_H_ |
7 | 7 |
8 #include "chrome/common/extensions/api/manifest_types.h" | 8 #include "chrome/common/extensions/api/manifest_types.h" |
9 #include "extensions/common/extension.h" | 9 #include "extensions/common/extension.h" |
10 #include "extensions/common/manifest_handler.h" | 10 #include "extensions/common/manifest_handler.h" |
11 | 11 |
12 namespace extensions { | 12 namespace extensions { |
13 | 13 |
14 class ManifestPermission; | 14 class ManifestPermission; |
15 | 15 |
16 // SettingsOverride is associated with "chrome_settings_overrides" manifest key. | 16 // SettingsOverride is associated with "chrome_settings_overrides" manifest key. |
17 // An extension can add a search engine as default or non-default, overwrite the | 17 // An extension can add a search engine as default or non-default, overwrite the |
18 // homepage and append a startup page to the list. | 18 // homepage and append a startup page to the list. |
19 struct SettingsOverrides : public Extension::ManifestData { | 19 struct SettingsOverrides : public Extension::ManifestData { |
Finnur
2014/02/05 13:37:40
This isn't purely about data anymore - Why is this
Mike Wittman
2014/02/05 19:17:07
Mainly for consistency with the other subclasses o
| |
20 SettingsOverrides(); | 20 SettingsOverrides(); |
21 virtual ~SettingsOverrides(); | 21 virtual ~SettingsOverrides(); |
22 | 22 |
23 static const SettingsOverrides* Get(const Extension* extension); | 23 static const SettingsOverrides* Get(const Extension* extension); |
24 | 24 |
25 bool RemovesBookmarkButton() const; | 25 bool RemovesBookmarkButton() const; |
26 bool RemovesBookmarkShortcut() const; | |
26 | 27 |
27 scoped_ptr<api::manifest_types::ChromeSettingsOverrides::Bookmarks_ui> | 28 scoped_ptr<api::manifest_types::ChromeSettingsOverrides::Bookmarks_ui> |
28 bookmarks_ui; | 29 bookmarks_ui; |
29 scoped_ptr<api::manifest_types::ChromeSettingsOverrides::Search_provider> | 30 scoped_ptr<api::manifest_types::ChromeSettingsOverrides::Search_provider> |
30 search_engine; | 31 search_engine; |
31 scoped_ptr<GURL> homepage; | 32 scoped_ptr<GURL> homepage; |
32 std::vector<GURL> startup_pages; | 33 std::vector<GURL> startup_pages; |
33 | 34 |
34 scoped_ptr<ManifestPermission> manifest_permission; | 35 scoped_ptr<ManifestPermission> manifest_permission; |
35 | 36 |
(...skipping 18 matching lines...) Expand all Loading... | |
54 private: | 55 private: |
55 class ManifestPermissionImpl; | 56 class ManifestPermissionImpl; |
56 | 57 |
57 virtual const std::vector<std::string> Keys() const OVERRIDE; | 58 virtual const std::vector<std::string> Keys() const OVERRIDE; |
58 | 59 |
59 DISALLOW_COPY_AND_ASSIGN(SettingsOverridesHandler); | 60 DISALLOW_COPY_AND_ASSIGN(SettingsOverridesHandler); |
60 }; | 61 }; |
61 | 62 |
62 } // namespace extensions | 63 } // namespace extensions |
63 #endif // CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER _H_ | 64 #endif // CHROME_COMMON_EXTENSIONS_MANIFEST_HANDLERS_SETTINGS_OVERRIDES_HANDLER _H_ |
OLD | NEW |