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

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

Issue 345823002: Move ownership of ChildFrameCompositingHelper from frame to proxy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes based on Ken's review and fix for Android. Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_PROXY_H_ 5 #ifndef CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
6 #define CONTENT_RENDERER_RENDER_FRAME_PROXY_H_ 6 #define CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h"
9 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
10 #include "ipc/ipc_listener.h" 11 #include "ipc/ipc_listener.h"
11 #include "ipc/ipc_sender.h" 12 #include "ipc/ipc_sender.h"
12 13
13 #include "third_party/WebKit/public/web/WebFrameClient.h" 14 #include "third_party/WebKit/public/web/WebFrameClient.h"
14 #include "third_party/WebKit/public/web/WebRemoteFrame.h" 15 #include "third_party/WebKit/public/web/WebRemoteFrame.h"
15 16
17 struct FrameMsg_BuffersSwapped_Params;
18 struct FrameMsg_CompositorFrameSwapped_Params;
19
16 namespace content { 20 namespace content {
17 21
22 class ChildFrameCompositingHelper;
18 class RenderFrameImpl; 23 class RenderFrameImpl;
19 class RenderViewImpl; 24 class RenderViewImpl;
20 25
21 // When a page's frames are rendered by multiple processes, each renderer has a 26 // When a page's frames are rendered by multiple processes, each renderer has a
22 // full copy of the frame tree. It has full RenderFrames for the frames it is 27 // full copy of the frame tree. It has full RenderFrames for the frames it is
23 // responsible for rendering and placeholder objects for frames rendered by 28 // responsible for rendering and placeholder objects for frames rendered by
24 // other processes. This class is the renderer-side object for the placeholder. 29 // other processes. This class is the renderer-side object for the placeholder.
25 // RenderFrameProxy allows us to keep existing window references valid over 30 // RenderFrameProxy allows us to keep existing window references valid over
26 // cross-process navigations and route cross-site asynchronous JavaScript calls, 31 // cross-process navigations and route cross-site asynchronous JavaScript calls,
27 // such as postMessage. 32 // such as postMessage.
(...skipping 23 matching lines...) Expand all
51 56
52 virtual ~RenderFrameProxy(); 57 virtual ~RenderFrameProxy();
53 58
54 // IPC::Sender 59 // IPC::Sender
55 virtual bool Send(IPC::Message* msg) OVERRIDE; 60 virtual bool Send(IPC::Message* msg) OVERRIDE;
56 61
57 RenderFrameImpl* render_frame() { 62 RenderFrameImpl* render_frame() {
58 return render_frame_; 63 return render_frame_;
59 } 64 }
60 65
66 // Out-of-process child frames receive a signal from RenderWidgetCompositor
67 // when a compositor frame has committed.
68 void DidCommitCompositorFrame();
69
61 private: 70 private:
62 RenderFrameProxy(int routing_id, int frame_routing_id); 71 RenderFrameProxy(int routing_id, int frame_routing_id);
63 72
64 // IPC::Listener 73 // IPC::Listener
65 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; 74 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE;
66 75
67 // IPC handlers 76 // IPC handlers
68 void OnDeleteProxy(); 77 void OnDeleteProxy();
78 void OnChildFrameProcessGone();
79 void OnBuffersSwapped(const FrameMsg_BuffersSwapped_Params& params);
80 void OnCompositorFrameSwapped(const IPC::Message& message);
81
82 blink::WebFrame* GetWebFrame();
69 83
70 int routing_id_; 84 int routing_id_;
71 int frame_routing_id_; 85 int frame_routing_id_;
72 RenderFrameImpl* render_frame_; 86 RenderFrameImpl* render_frame_;
73 87
88 scoped_refptr<ChildFrameCompositingHelper> compositing_helper_;
89
74 DISALLOW_COPY_AND_ASSIGN(RenderFrameProxy); 90 DISALLOW_COPY_AND_ASSIGN(RenderFrameProxy);
75 }; 91 };
76 92
77 } // namespace 93 } // namespace
78 94
79 #endif // CONTENT_RENDERER_RENDER_FRAME_PROXY_H_ 95 #endif // CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698