| 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_HOST_DELEGATE_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
| 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/i18n/rtl.h" | 11 #include "base/i18n/rtl.h" |
| 12 #include "content/common/content_export.h" | 12 #include "content/common/content_export.h" |
| 13 #include "content/common/frame_message_enums.h" | 13 #include "content/common/frame_message_enums.h" |
| 14 #include "content/public/browser/site_instance.h" |
| 14 #include "content/public/common/javascript_message_type.h" | 15 #include "content/public/common/javascript_message_type.h" |
| 15 #include "content/public/common/media_stream_request.h" | 16 #include "content/public/common/media_stream_request.h" |
| 16 #include "net/http/http_response_headers.h" | 17 #include "net/http/http_response_headers.h" |
| 17 | 18 |
| 18 #if defined(OS_WIN) | 19 #if defined(OS_WIN) |
| 19 #include "ui/gfx/native_widget_types.h" | 20 #include "ui/gfx/native_widget_types.h" |
| 20 #endif | 21 #endif |
| 21 | 22 |
| 22 class GURL; | 23 class GURL; |
| 23 | 24 |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 // Gets the GeolocationServiceContext associated with this delegate. | 162 // Gets the GeolocationServiceContext associated with this delegate. |
| 162 virtual GeolocationServiceContext* GetGeolocationServiceContext(); | 163 virtual GeolocationServiceContext* GetGeolocationServiceContext(); |
| 163 | 164 |
| 164 // Notification that the frame wants to go into fullscreen mode. | 165 // Notification that the frame wants to go into fullscreen mode. |
| 165 // |origin| represents the origin of the frame that requests fullscreen. | 166 // |origin| represents the origin of the frame that requests fullscreen. |
| 166 virtual void EnterFullscreenMode(const GURL& origin) {} | 167 virtual void EnterFullscreenMode(const GURL& origin) {} |
| 167 | 168 |
| 168 // Notification that the frame wants to go out of fullscreen mode. | 169 // Notification that the frame wants to go out of fullscreen mode. |
| 169 virtual void ExitFullscreenMode() {} | 170 virtual void ExitFullscreenMode() {} |
| 170 | 171 |
| 172 // Let the delegate decide whether postMessage should be delivered to |
| 173 // |target_rfh| from a source frame in the given SiteInstance. |
| 174 virtual bool ShouldRouteMessageEvent( |
| 175 RenderFrameHost* target_rfh, |
| 176 SiteInstance* source_site_instance) const; |
| 177 |
| 178 // Ensure that |render_frame_host| has swapped-out RenderViews and proxies |
| 179 // for itself and for each frame on its opener chain in the current frame's |
| 180 // SiteInstance. Returns the routing ID of the swapped-out RenderView |
| 181 // corresponding to |render_frame_host|. |
| 182 // |
| 183 // TODO(alexmos): This method will be removed once opener tracking and |
| 184 // CreateOpenerRenderViews moves out of WebContents and into lower layers, as |
| 185 // part of https://crbug.com/225940. Currently, this method temporarily |
| 186 // supports cross-process postMessage in non-site-per-process mode, where we |
| 187 // need to create any missing proxies for the message's source frame and its |
| 188 // opener chain on demand. |
| 189 virtual int EnsureOpenerRenderViewsExist(RenderFrameHost* render_frame_host); |
| 190 |
| 171 #if defined(OS_WIN) | 191 #if defined(OS_WIN) |
| 172 // Returns the frame's parent's NativeViewAccessible. | 192 // Returns the frame's parent's NativeViewAccessible. |
| 173 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible(); | 193 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible(); |
| 174 #endif | 194 #endif |
| 175 | 195 |
| 176 protected: | 196 protected: |
| 177 virtual ~RenderFrameHostDelegate() {} | 197 virtual ~RenderFrameHostDelegate() {} |
| 178 }; | 198 }; |
| 179 | 199 |
| 180 } // namespace content | 200 } // namespace content |
| 181 | 201 |
| 182 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 202 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
| OLD | NEW |