Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ |
| 6 #define CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ | 6 #define CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 35 virtual void AddLocalizedStrings( | 35 virtual void AddLocalizedStrings( |
| 36 const base::DictionaryValue& localized_strings) OVERRIDE; | 36 const base::DictionaryValue& localized_strings) OVERRIDE; |
| 37 virtual void AddBoolean(const std::string& name, bool value) OVERRIDE; | 37 virtual void AddBoolean(const std::string& name, bool value) OVERRIDE; |
| 38 virtual void SetJsonPath(const std::string& path) OVERRIDE; | 38 virtual void SetJsonPath(const std::string& path) OVERRIDE; |
| 39 virtual void SetUseJsonJSFormatV2() OVERRIDE; | 39 virtual void SetUseJsonJSFormatV2() OVERRIDE; |
| 40 virtual void AddResourcePath(const std::string &path, | 40 virtual void AddResourcePath(const std::string &path, |
| 41 int resource_id) OVERRIDE; | 41 int resource_id) OVERRIDE; |
| 42 virtual void SetDefaultResource(int resource_id) OVERRIDE; | 42 virtual void SetDefaultResource(int resource_id) OVERRIDE; |
| 43 virtual void SetRequestFilter( | 43 virtual void SetRequestFilter( |
| 44 const WebUIDataSource::HandleRequestCallback& callback) OVERRIDE; | 44 const WebUIDataSource::HandleRequestCallback& callback) OVERRIDE; |
| 45 // Currently only used by embedders for WebUIs with multiple instances, could | |
|
jam
2013/08/13 21:36:45
nit: method comments go on the interface and not t
| |
| 46 // have been useful for NTP as well if it wasn't implementing | |
| 47 // URLDataSourceImpl itself. | |
| 48 virtual void DisableReplaceExistingSource() OVERRIDE; | |
| 45 virtual void DisableContentSecurityPolicy() OVERRIDE; | 49 virtual void DisableContentSecurityPolicy() OVERRIDE; |
| 46 virtual void OverrideContentSecurityPolicyObjectSrc( | 50 virtual void OverrideContentSecurityPolicyObjectSrc( |
| 47 const std::string& data) OVERRIDE; | 51 const std::string& data) OVERRIDE; |
| 48 virtual void OverrideContentSecurityPolicyFrameSrc( | 52 virtual void OverrideContentSecurityPolicyFrameSrc( |
| 49 const std::string& data) OVERRIDE; | 53 const std::string& data) OVERRIDE; |
| 50 virtual void DisableDenyXFrameOptions() OVERRIDE; | 54 virtual void DisableDenyXFrameOptions() OVERRIDE; |
| 51 | 55 |
| 52 protected: | 56 protected: |
| 53 virtual ~WebUIDataSourceImpl(); | 57 virtual ~WebUIDataSourceImpl(); |
| 54 | 58 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 92 std::map<std::string, int> path_to_idr_map_; | 96 std::map<std::string, int> path_to_idr_map_; |
| 93 base::DictionaryValue localized_strings_; | 97 base::DictionaryValue localized_strings_; |
| 94 WebUIDataSource::HandleRequestCallback filter_callback_; | 98 WebUIDataSource::HandleRequestCallback filter_callback_; |
| 95 bool add_csp_; | 99 bool add_csp_; |
| 96 bool object_src_set_; | 100 bool object_src_set_; |
| 97 std::string object_src_; | 101 std::string object_src_; |
| 98 bool frame_src_set_; | 102 bool frame_src_set_; |
| 99 std::string frame_src_; | 103 std::string frame_src_; |
| 100 bool deny_xframe_options_; | 104 bool deny_xframe_options_; |
| 101 bool disable_set_font_strings_; | 105 bool disable_set_font_strings_; |
| 106 bool replace_existing_source_; | |
| 102 | 107 |
| 103 DISALLOW_COPY_AND_ASSIGN(WebUIDataSourceImpl); | 108 DISALLOW_COPY_AND_ASSIGN(WebUIDataSourceImpl); |
| 104 }; | 109 }; |
| 105 | 110 |
| 106 } // content | 111 } // content |
| 107 | 112 |
| 108 #endif // CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ | 113 #endif // CONTENT_BROWSER_WEBUI_WEB_UI_DATA_SOURCE_IMPL_H_ |
| OLD | NEW |