| 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 CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ |
| 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <set> | 10 #include <set> |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 friend class BrowserThread; | 73 friend class BrowserThread; |
| 74 friend class base::DeleteHelper<RenderFrameMessageFilter>; | 74 friend class base::DeleteHelper<RenderFrameMessageFilter>; |
| 75 | 75 |
| 76 class OpenChannelToPpapiPluginCallback; | 76 class OpenChannelToPpapiPluginCallback; |
| 77 class OpenChannelToPpapiBrokerCallback; | 77 class OpenChannelToPpapiBrokerCallback; |
| 78 | 78 |
| 79 ~RenderFrameMessageFilter() override; | 79 ~RenderFrameMessageFilter() override; |
| 80 | 80 |
| 81 void OnCreateChildFrame(const FrameHostMsg_CreateChildFrame_Params& params, | 81 void OnCreateChildFrame(const FrameHostMsg_CreateChildFrame_Params& params, |
| 82 int* new_render_frame_id); | 82 int* new_render_frame_id); |
| 83 void OnGetCookies(int render_frame_id, | |
| 84 const GURL& url, | |
| 85 const GURL& first_party_for_cookies, | |
| 86 IPC::Message* reply_msg); | |
| 87 void OnCookiesEnabled(int render_frame_id, | 83 void OnCookiesEnabled(int render_frame_id, |
| 88 const GURL& url, | 84 const GURL& url, |
| 89 const GURL& first_party_for_cookies, | 85 const GURL& first_party_for_cookies, |
| 90 bool* cookies_enabled); | 86 bool* cookies_enabled); |
| 91 | 87 |
| 92 // Check the policy for getting cookies. Gets the cookies if allowed. | 88 // Check the policy for getting cookies. Gets the cookies if allowed. |
| 93 void CheckPolicyForCookies(int render_frame_id, | 89 void CheckPolicyForCookies(int render_frame_id, |
| 94 const GURL& url, | 90 const GURL& url, |
| 95 const GURL& first_party_for_cookies, | 91 const GURL& first_party_for_cookies, |
| 96 IPC::Message* reply_msg, | 92 const GetCookiesCallback& callback, |
| 97 const net::CookieList& cookie_list); | 93 const net::CookieList& cookie_list); |
| 98 | 94 |
| 99 // Writes the cookies to reply messages, and sends the message. | |
| 100 // Callback functions for getting cookies from cookie store. | |
| 101 void SendGetCookiesResponse(IPC::Message* reply_msg, | |
| 102 const std::string& cookies); | |
| 103 | |
| 104 void OnDownloadUrl(int render_view_id, | 95 void OnDownloadUrl(int render_view_id, |
| 105 int render_frame_id, | 96 int render_frame_id, |
| 106 const GURL& url, | 97 const GURL& url, |
| 107 const Referrer& referrer, | 98 const Referrer& referrer, |
| 108 const base::string16& suggested_name); | 99 const base::string16& suggested_name); |
| 109 void OnSaveImageFromDataURL(int render_view_id, | 100 void OnSaveImageFromDataURL(int render_view_id, |
| 110 int render_frame_id, | 101 int render_frame_id, |
| 111 const std::string& url_str); | 102 const std::string& url_str); |
| 112 | 103 |
| 113 void OnAre3DAPIsBlocked(int render_frame_id, | 104 void OnAre3DAPIsBlocked(int render_frame_id, |
| 114 const GURL& top_origin_url, | 105 const GURL& top_origin_url, |
| 115 ThreeDAPIType requester, | 106 ThreeDAPIType requester, |
| 116 bool* blocked); | 107 bool* blocked); |
| 117 | 108 |
| 118 void OnRenderProcessGone(); | 109 void OnRenderProcessGone(); |
| 119 | 110 |
| 120 // mojom::RenderFrameMessageFilter: | 111 // mojom::RenderFrameMessageFilter: |
| 121 void SetCookie(int32_t render_frame_id, | 112 void SetCookie(int32_t render_frame_id, |
| 122 const GURL& url, | 113 const GURL& url, |
| 123 const GURL& first_party_for_cookies, | 114 const GURL& first_party_for_cookies, |
| 124 const mojo::String& cookie) override; | 115 const mojo::String& cookie) override; |
| 116 void GetCookies(int render_frame_id, |
| 117 const GURL& url, |
| 118 const GURL& first_party_for_cookies, |
| 119 const GetCookiesCallback& callback) override; |
| 125 | 120 |
| 126 | 121 |
| 127 #if defined(ENABLE_PLUGINS) | 122 #if defined(ENABLE_PLUGINS) |
| 128 void OnGetPlugins(bool refresh, IPC::Message* reply_msg); | 123 void OnGetPlugins(bool refresh, IPC::Message* reply_msg); |
| 129 void GetPluginsCallback(IPC::Message* reply_msg, | 124 void GetPluginsCallback(IPC::Message* reply_msg, |
| 130 const std::vector<WebPluginInfo>& plugins); | 125 const std::vector<WebPluginInfo>& plugins); |
| 131 void OnGetPluginInfo(int render_frame_id, | 126 void OnGetPluginInfo(int render_frame_id, |
| 132 const GURL& url, | 127 const GURL& url, |
| 133 const GURL& policy_url, | 128 const GURL& policy_url, |
| 134 const std::string& mime_type, | 129 const std::string& mime_type, |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 176 | 171 |
| 177 // Whether this process is used for incognito contents. | 172 // Whether this process is used for incognito contents. |
| 178 bool incognito_; | 173 bool incognito_; |
| 179 | 174 |
| 180 const int render_process_id_; | 175 const int render_process_id_; |
| 181 }; | 176 }; |
| 182 | 177 |
| 183 } // namespace content | 178 } // namespace content |
| 184 | 179 |
| 185 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ | 180 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_MESSAGE_FILTER_H_ |
| OLD | NEW |