| OLD | NEW |
| 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 #ifndef CHROME_COMMON_EXTENSIONS_EXTENSION_H_ | 5 #ifndef CHROME_COMMON_EXTENSIONS_EXTENSION_H_ |
| 6 #define CHROME_COMMON_EXTENSIONS_EXTENSION_H_ | 6 #define CHROME_COMMON_EXTENSIONS_EXTENSION_H_ |
| 7 | 7 |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <iosfwd> | 9 #include <iosfwd> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 566 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 577 const std::string& launch_local_path() const { return launch_local_path_; } | 577 const std::string& launch_local_path() const { return launch_local_path_; } |
| 578 const std::string& launch_web_url() const { return launch_web_url_; } | 578 const std::string& launch_web_url() const { return launch_web_url_; } |
| 579 extension_misc::LaunchContainer launch_container() const { | 579 extension_misc::LaunchContainer launch_container() const { |
| 580 return launch_container_; | 580 return launch_container_; |
| 581 } | 581 } |
| 582 int launch_width() const { return launch_width_; } | 582 int launch_width() const { return launch_width_; } |
| 583 int launch_height() const { return launch_height_; } | 583 int launch_height() const { return launch_height_; } |
| 584 | 584 |
| 585 // Theme-related. | 585 // Theme-related. |
| 586 bool is_theme() const; | 586 bool is_theme() const; |
| 587 base::DictionaryValue* GetThemeImages() const { return theme_images_.get(); } | |
| 588 base::DictionaryValue* GetThemeColors() const {return theme_colors_.get(); } | |
| 589 base::DictionaryValue* GetThemeTints() const { return theme_tints_.get(); } | |
| 590 base::DictionaryValue* GetThemeDisplayProperties() const { | |
| 591 return theme_display_properties_.get(); | |
| 592 } | |
| 593 | 587 |
| 594 // Content Security Policy! | 588 // Content Security Policy! |
| 595 const std::string& content_security_policy() const { | 589 const std::string& content_security_policy() const { |
| 596 return content_security_policy_; | 590 return content_security_policy_; |
| 597 } | 591 } |
| 598 | 592 |
| 599 // Content pack related. | 593 // Content pack related. |
| 600 bool is_content_pack() const; | 594 bool is_content_pack() const; |
| 601 ExtensionResource GetContentPackSiteList() const; | 595 ExtensionResource GetContentPackSiteList() const; |
| 602 | 596 |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 708 string16* error); | 702 string16* error); |
| 709 bool LoadExtensionFeatures(APIPermissionSet* api_permissions, | 703 bool LoadExtensionFeatures(APIPermissionSet* api_permissions, |
| 710 string16* error); | 704 string16* error); |
| 711 bool LoadContentScripts(string16* error); | 705 bool LoadContentScripts(string16* error); |
| 712 bool LoadPageAction(string16* error); | 706 bool LoadPageAction(string16* error); |
| 713 bool LoadBrowserAction(string16* error); | 707 bool LoadBrowserAction(string16* error); |
| 714 bool LoadSystemIndicator(APIPermissionSet* api_permissions, string16* error); | 708 bool LoadSystemIndicator(APIPermissionSet* api_permissions, string16* error); |
| 715 bool LoadTextToSpeechVoices(string16* error); | 709 bool LoadTextToSpeechVoices(string16* error); |
| 716 bool LoadIncognitoMode(string16* error); | 710 bool LoadIncognitoMode(string16* error); |
| 717 bool LoadContentSecurityPolicy(string16* error); | 711 bool LoadContentSecurityPolicy(string16* error); |
| 718 | |
| 719 bool LoadThemeFeatures(string16* error); | |
| 720 bool LoadThemeImages(const base::DictionaryValue* theme_value, | |
| 721 string16* error); | |
| 722 bool LoadThemeColors(const base::DictionaryValue* theme_value, | |
| 723 string16* error); | |
| 724 bool LoadThemeTints(const base::DictionaryValue* theme_value, | |
| 725 string16* error); | |
| 726 bool LoadThemeDisplayProperties(const base::DictionaryValue* theme_value, | |
| 727 string16* error); | |
| 728 | |
| 729 bool LoadManagedModeFeatures(string16* error); | 712 bool LoadManagedModeFeatures(string16* error); |
| 730 bool LoadManagedModeSites( | 713 bool LoadManagedModeSites( |
| 731 const base::DictionaryValue* content_pack_value, | 714 const base::DictionaryValue* content_pack_value, |
| 732 string16* error); | 715 string16* error); |
| 733 bool LoadManagedModeConfigurations( | 716 bool LoadManagedModeConfigurations( |
| 734 const base::DictionaryValue* content_pack_value, | 717 const base::DictionaryValue* content_pack_value, |
| 735 string16* error); | 718 string16* error); |
| 736 | 719 |
| 737 // Helper function for implementing HasCachedImage/GetCachedImage. A return | 720 // Helper function for implementing HasCachedImage/GetCachedImage. A return |
| 738 // value of NULL means there is no matching image cached (we allow caching an | 721 // value of NULL means there is no matching image cached (we allow caching an |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 886 | 869 |
| 887 // True if the background page can be scripted by pages of the app or | 870 // True if the background page can be scripted by pages of the app or |
| 888 // extension, in which case all such pages must run in the same process. | 871 // extension, in which case all such pages must run in the same process. |
| 889 // False if such pages are not permitted to script the background page, | 872 // False if such pages are not permitted to script the background page, |
| 890 // allowing them to run in different processes. | 873 // allowing them to run in different processes. |
| 891 bool allow_background_js_access_; | 874 bool allow_background_js_access_; |
| 892 | 875 |
| 893 // The public key used to sign the contents of the crx package. | 876 // The public key used to sign the contents of the crx package. |
| 894 std::string public_key_; | 877 std::string public_key_; |
| 895 | 878 |
| 896 // A map of resource id's to relative file paths. | |
| 897 scoped_ptr<base::DictionaryValue> theme_images_; | |
| 898 | |
| 899 // A map of color names to colors. | |
| 900 scoped_ptr<base::DictionaryValue> theme_colors_; | |
| 901 | |
| 902 // A map of color names to colors. | |
| 903 scoped_ptr<base::DictionaryValue> theme_tints_; | |
| 904 | |
| 905 // A map of display properties. | |
| 906 scoped_ptr<base::DictionaryValue> theme_display_properties_; | |
| 907 | |
| 908 // A file containing a list of sites for Managed Mode. | 879 // A file containing a list of sites for Managed Mode. |
| 909 FilePath content_pack_site_list_; | 880 FilePath content_pack_site_list_; |
| 910 | 881 |
| 911 // The manifest from which this extension was created. | 882 // The manifest from which this extension was created. |
| 912 scoped_ptr<Manifest> manifest_; | 883 scoped_ptr<Manifest> manifest_; |
| 913 | 884 |
| 914 // Stored parsed manifest data. | 885 // Stored parsed manifest data. |
| 915 ManifestDataMap manifest_data_; | 886 ManifestDataMap manifest_data_; |
| 916 | 887 |
| 917 // Set to true at the end of InitValue when initialization is finished. | 888 // Set to true at the end of InitValue when initialization is finished. |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1023 | 994 |
| 1024 UpdatedExtensionPermissionsInfo( | 995 UpdatedExtensionPermissionsInfo( |
| 1025 const Extension* extension, | 996 const Extension* extension, |
| 1026 const PermissionSet* permissions, | 997 const PermissionSet* permissions, |
| 1027 Reason reason); | 998 Reason reason); |
| 1028 }; | 999 }; |
| 1029 | 1000 |
| 1030 } // namespace extensions | 1001 } // namespace extensions |
| 1031 | 1002 |
| 1032 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_H_ | 1003 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_H_ |
| OLD | NEW |