| 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_RENDERER_RENDER_FRAME_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
| 6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 #endif | 36 #endif |
| 37 | 37 |
| 38 #if defined(OS_ANDROID) | 38 #if defined(OS_ANDROID) |
| 39 #include "content/renderer/media/android/renderer_media_player_manager.h" | 39 #include "content/renderer/media/android/renderer_media_player_manager.h" |
| 40 #endif | 40 #endif |
| 41 | 41 |
| 42 class GURL; | 42 class GURL; |
| 43 class TransportDIB; | 43 class TransportDIB; |
| 44 struct FrameHostMsg_AddNavigationTransitionData_Params; | 44 struct FrameHostMsg_AddNavigationTransitionData_Params; |
| 45 struct FrameMsg_Navigate_Params; | 45 struct FrameMsg_Navigate_Params; |
| 46 struct FrameMsg_NewFrame_WidgetParams; |
| 46 struct FrameMsg_RequestNavigation_Params; | 47 struct FrameMsg_RequestNavigation_Params; |
| 47 | 48 |
| 48 namespace blink { | 49 namespace blink { |
| 49 class WebGeolocationClient; | 50 class WebGeolocationClient; |
| 50 class WebMouseEvent; | 51 class WebMouseEvent; |
| 51 class WebContentDecryptionModule; | 52 class WebContentDecryptionModule; |
| 52 class WebMediaPlayer; | 53 class WebMediaPlayer; |
| 53 class WebPushClient; | 54 class WebPushClient; |
| 54 class WebSecurityOrigin; | 55 class WebSecurityOrigin; |
| 55 struct WebCompositionUnderline; | 56 struct WebCompositionUnderline; |
| 56 struct WebContextMenuData; | 57 struct WebContextMenuData; |
| 57 struct WebCursorInfo; | 58 struct WebCursorInfo; |
| 58 struct WebTransitionElementData; | 59 struct WebTransitionElementData; |
| 59 } | 60 } |
| 60 | 61 |
| 61 namespace gfx { | 62 namespace gfx { |
| 62 class Point; | 63 class Point; |
| 63 class Range; | 64 class Range; |
| 64 class Rect; | 65 class Rect; |
| 65 } | 66 } |
| 66 | 67 |
| 67 namespace media { | 68 namespace media { |
| 68 class WebEncryptedMediaClientImpl; | 69 class WebEncryptedMediaClientImpl; |
| 69 } | 70 } |
| 70 | 71 |
| 71 namespace content { | 72 namespace content { |
| 72 | 73 |
| 73 class ChildFrameCompositingHelper; | 74 class ChildFrameCompositingHelper; |
| 75 class CompositorDependencies; |
| 74 class ExternalPopupMenu; | 76 class ExternalPopupMenu; |
| 75 class GeolocationDispatcher; | 77 class GeolocationDispatcher; |
| 76 class ManifestManager; | 78 class ManifestManager; |
| 77 class MediaStreamDispatcher; | 79 class MediaStreamDispatcher; |
| 78 class MediaStreamRendererFactory; | 80 class MediaStreamRendererFactory; |
| 79 class MidiDispatcher; | 81 class MidiDispatcher; |
| 80 class NotificationPermissionDispatcher; | 82 class NotificationPermissionDispatcher; |
| 81 class PageState; | 83 class PageState; |
| 82 class PepperPluginInstanceImpl; | 84 class PepperPluginInstanceImpl; |
| 83 class PushMessagingDispatcher; | 85 class PushMessagingDispatcher; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 // identified by |parent_routing_id| or as the top-level frame if the latter | 117 // identified by |parent_routing_id| or as the top-level frame if the latter |
| 116 // is MSG_ROUTING_NONE. If |proxy_routing_id| is MSG_ROUTING_NONE, it creates | 118 // is MSG_ROUTING_NONE. If |proxy_routing_id| is MSG_ROUTING_NONE, it creates |
| 117 // the Blink WebLocalFrame and inserts it in the proper place in the frame | 119 // the Blink WebLocalFrame and inserts it in the proper place in the frame |
| 118 // tree. Otherwise, the frame is semi-orphaned until it commits, at which | 120 // tree. Otherwise, the frame is semi-orphaned until it commits, at which |
| 119 // point it replaces the proxy identified by |proxy_routing_id|. | 121 // point it replaces the proxy identified by |proxy_routing_id|. |
| 120 // Note: This is called only when RenderFrame is being created in response to | 122 // Note: This is called only when RenderFrame is being created in response to |
| 121 // IPC message from the browser process. All other frame creation is driven | 123 // IPC message from the browser process. All other frame creation is driven |
| 122 // through Blink and Create. | 124 // through Blink and Create. |
| 123 static void CreateFrame(int routing_id, | 125 static void CreateFrame(int routing_id, |
| 124 int parent_routing_id, | 126 int parent_routing_id, |
| 125 int proxy_routing_id); | 127 int proxy_routing_id, |
| 128 CompositorDependencies* compositor_deps, |
| 129 const FrameMsg_NewFrame_WidgetParams& params); |
| 126 | 130 |
| 127 // Returns the RenderFrameImpl for the given routing ID. | 131 // Returns the RenderFrameImpl for the given routing ID. |
| 128 static RenderFrameImpl* FromRoutingID(int routing_id); | 132 static RenderFrameImpl* FromRoutingID(int routing_id); |
| 129 | 133 |
| 130 // Just like RenderFrame::FromWebFrame but returns the implementation. | 134 // Just like RenderFrame::FromWebFrame but returns the implementation. |
| 131 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); | 135 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); |
| 132 | 136 |
| 133 // Used by content_layouttest_support to hook into the creation of | 137 // Used by content_layouttest_support to hook into the creation of |
| 134 // RenderFrameImpls. | 138 // RenderFrameImpls. |
| 135 using CreateRenderFrameImplFunction = RenderFrameImpl* (*)(RenderViewImpl*, | 139 using CreateRenderFrameImplFunction = RenderFrameImpl* (*)(RenderViewImpl*, |
| (...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 718 // RenderFrame. See https://crbug.com/357747. | 722 // RenderFrame. See https://crbug.com/357747. |
| 719 RenderFrameProxy* render_frame_proxy_; | 723 RenderFrameProxy* render_frame_proxy_; |
| 720 bool is_detaching_; | 724 bool is_detaching_; |
| 721 | 725 |
| 722 // If this frame was created to replace a proxy, this will store the routing | 726 // If this frame was created to replace a proxy, this will store the routing |
| 723 // id of the proxy to replace at commit-time, at which time it will be | 727 // id of the proxy to replace at commit-time, at which time it will be |
| 724 // cleared. | 728 // cleared. |
| 725 // TODO(creis): Remove this after switching to PlzNavigate. | 729 // TODO(creis): Remove this after switching to PlzNavigate. |
| 726 int proxy_routing_id_; | 730 int proxy_routing_id_; |
| 727 | 731 |
| 732 // Used when the RenderFrame is a local root. For now, RenderWidgets are |
| 733 // added only when a child frame is in a different process from its parent |
| 734 // frame, but eventually this will also apply to top-level frames. |
| 735 // TODO(kenrb): Correct the above statement when top-level frames have their |
| 736 // own RenderWidgets. |
| 737 scoped_refptr<RenderWidget> render_widget_; |
| 738 |
| 728 #if defined(ENABLE_PLUGINS) | 739 #if defined(ENABLE_PLUGINS) |
| 729 // Current text input composition text. Empty if no composition is in | 740 // Current text input composition text. Empty if no composition is in |
| 730 // progress. | 741 // progress. |
| 731 base::string16 pepper_composition_text_; | 742 base::string16 pepper_composition_text_; |
| 732 | 743 |
| 733 PluginPowerSaverHelper* plugin_power_saver_helper_; | 744 PluginPowerSaverHelper* plugin_power_saver_helper_; |
| 734 #endif | 745 #endif |
| 735 | 746 |
| 736 RendererWebCookieJarImpl cookie_jar_; | 747 RendererWebCookieJarImpl cookie_jar_; |
| 737 | 748 |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 836 #endif | 847 #endif |
| 837 | 848 |
| 838 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; | 849 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; |
| 839 | 850 |
| 840 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); | 851 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); |
| 841 }; | 852 }; |
| 842 | 853 |
| 843 } // namespace content | 854 } // namespace content |
| 844 | 855 |
| 845 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ | 856 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
| OLD | NEW |