Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(397)

Side by Side Diff: content/renderer/render_frame_impl.h

Issue 616133002: Make RenderFrame(Host) own a RenderWidget(Host). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Re-applying same patch Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 // is MSG_ROUTING_NONE. If |proxy_routing_id| is MSG_ROUTING_NONE, it creates 119 // is MSG_ROUTING_NONE. If |proxy_routing_id| is MSG_ROUTING_NONE, it creates
118 // the Blink WebLocalFrame and inserts it in the proper place in the frame 120 // the Blink WebLocalFrame and inserts it in the proper place in the frame
119 // tree. Otherwise, the frame is semi-orphaned until it commits, at which 121 // tree. Otherwise, the frame is semi-orphaned until it commits, at which
120 // point it replaces the proxy identified by |proxy_routing_id|. 122 // point it replaces the proxy identified by |proxy_routing_id|.
121 // Note: This is called only when RenderFrame is being created in response to 123 // Note: This is called only when RenderFrame is being created in response to
122 // IPC message from the browser process. All other frame creation is driven 124 // IPC message from the browser process. All other frame creation is driven
123 // through Blink and Create. 125 // through Blink and Create.
124 static void CreateFrame(int routing_id, 126 static void CreateFrame(int routing_id,
125 int parent_routing_id, 127 int parent_routing_id,
126 int proxy_routing_id, 128 int proxy_routing_id,
127 const FrameReplicationState& replicated_state); 129 const FrameReplicationState& replicated_state,
130 CompositorDependencies* compositor_deps,
131 const FrameMsg_NewFrame_WidgetParams& params);
128 132
129 // Returns the RenderFrameImpl for the given routing ID. 133 // Returns the RenderFrameImpl for the given routing ID.
130 static RenderFrameImpl* FromRoutingID(int routing_id); 134 static RenderFrameImpl* FromRoutingID(int routing_id);
131 135
132 // Just like RenderFrame::FromWebFrame but returns the implementation. 136 // Just like RenderFrame::FromWebFrame but returns the implementation.
133 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); 137 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame);
134 138
135 // Used by content_layouttest_support to hook into the creation of 139 // Used by content_layouttest_support to hook into the creation of
136 // RenderFrameImpls. 140 // RenderFrameImpls.
137 using CreateRenderFrameImplFunction = RenderFrameImpl* (*)(RenderViewImpl*, 141 using CreateRenderFrameImplFunction = RenderFrameImpl* (*)(RenderViewImpl*,
(...skipping 596 matching lines...) Expand 10 before | Expand all | Expand 10 after
734 // RenderFrame. See https://crbug.com/357747. 738 // RenderFrame. See https://crbug.com/357747.
735 RenderFrameProxy* render_frame_proxy_; 739 RenderFrameProxy* render_frame_proxy_;
736 bool is_detaching_; 740 bool is_detaching_;
737 741
738 // If this frame was created to replace a proxy, this will store the routing 742 // If this frame was created to replace a proxy, this will store the routing
739 // id of the proxy to replace at commit-time, at which time it will be 743 // id of the proxy to replace at commit-time, at which time it will be
740 // cleared. 744 // cleared.
741 // TODO(creis): Remove this after switching to PlzNavigate. 745 // TODO(creis): Remove this after switching to PlzNavigate.
742 int proxy_routing_id_; 746 int proxy_routing_id_;
743 747
748 // Used when the RenderFrame is a local root. For now, RenderWidgets are
749 // added only when a child frame is in a different process from its parent
750 // frame, but eventually this will also apply to top-level frames.
751 // TODO(kenrb): Correct the above statement when top-level frames have their
752 // own RenderWidgets.
753 scoped_refptr<RenderWidget> render_widget_;
754
744 #if defined(ENABLE_PLUGINS) 755 #if defined(ENABLE_PLUGINS)
745 // Current text input composition text. Empty if no composition is in 756 // Current text input composition text. Empty if no composition is in
746 // progress. 757 // progress.
747 base::string16 pepper_composition_text_; 758 base::string16 pepper_composition_text_;
748 759
749 PluginPowerSaverHelper* plugin_power_saver_helper_; 760 PluginPowerSaverHelper* plugin_power_saver_helper_;
750 #endif 761 #endif
751 762
752 RendererWebCookieJarImpl cookie_jar_; 763 RendererWebCookieJarImpl cookie_jar_;
753 764
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
852 #endif 863 #endif
853 864
854 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; 865 base::WeakPtrFactory<RenderFrameImpl> weak_factory_;
855 866
856 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); 867 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl);
857 }; 868 };
858 869
859 } // namespace content 870 } // namespace content
860 871
861 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ 872 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698