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

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

Issue 974723002: OOPIF: Replicate dynamic window.name updates. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 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 #include "content/renderer/render_frame_proxy.h" 5 #include "content/renderer/render_frame_proxy.h"
6 6
7 #include <map> 7 #include <map>
8 8
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "content/child/webmessageportchannel_impl.h" 10 #include "content/child/webmessageportchannel_impl.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 bool handled = true; 179 bool handled = true;
180 IPC_BEGIN_MESSAGE_MAP(RenderFrameProxy, msg) 180 IPC_BEGIN_MESSAGE_MAP(RenderFrameProxy, msg)
181 IPC_MESSAGE_HANDLER(FrameMsg_DeleteProxy, OnDeleteProxy) 181 IPC_MESSAGE_HANDLER(FrameMsg_DeleteProxy, OnDeleteProxy)
182 IPC_MESSAGE_HANDLER(FrameMsg_ChildFrameProcessGone, OnChildFrameProcessGone) 182 IPC_MESSAGE_HANDLER(FrameMsg_ChildFrameProcessGone, OnChildFrameProcessGone)
183 IPC_MESSAGE_HANDLER_GENERIC(FrameMsg_CompositorFrameSwapped, 183 IPC_MESSAGE_HANDLER_GENERIC(FrameMsg_CompositorFrameSwapped,
184 OnCompositorFrameSwapped(msg)) 184 OnCompositorFrameSwapped(msg))
185 IPC_MESSAGE_HANDLER(FrameMsg_DisownOpener, OnDisownOpener) 185 IPC_MESSAGE_HANDLER(FrameMsg_DisownOpener, OnDisownOpener)
186 IPC_MESSAGE_HANDLER(FrameMsg_DidStartLoading, OnDidStartLoading) 186 IPC_MESSAGE_HANDLER(FrameMsg_DidStartLoading, OnDidStartLoading)
187 IPC_MESSAGE_HANDLER(FrameMsg_DidStopLoading, OnDidStopLoading) 187 IPC_MESSAGE_HANDLER(FrameMsg_DidStopLoading, OnDidStopLoading)
188 IPC_MESSAGE_HANDLER(FrameMsg_DispatchLoad, OnDispatchLoad) 188 IPC_MESSAGE_HANDLER(FrameMsg_DispatchLoad, OnDispatchLoad)
189 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateName, OnDidUpdateName)
189 IPC_MESSAGE_UNHANDLED(handled = false) 190 IPC_MESSAGE_UNHANDLED(handled = false)
190 IPC_END_MESSAGE_MAP() 191 IPC_END_MESSAGE_MAP()
191 192
192 // Note: If |handled| is true, |this| may have been deleted. 193 // Note: If |handled| is true, |this| may have been deleted.
193 return handled; 194 return handled;
194 } 195 }
195 196
196 bool RenderFrameProxy::Send(IPC::Message* message) { 197 bool RenderFrameProxy::Send(IPC::Message* message) {
197 return RenderThread::Get()->Send(message); 198 return RenderThread::Get()->Send(message);
198 } 199 }
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 if (IsMainFrameDetachedFromTree()) 261 if (IsMainFrameDetachedFromTree())
261 return; 262 return;
262 263
263 web_frame_->didStopLoading(); 264 web_frame_->didStopLoading();
264 } 265 }
265 266
266 void RenderFrameProxy::OnDispatchLoad() { 267 void RenderFrameProxy::OnDispatchLoad() {
267 web_frame_->DispatchLoadEventForFrameOwner(); 268 web_frame_->DispatchLoadEventForFrameOwner();
268 } 269 }
269 270
271 void RenderFrameProxy::OnDidUpdateName(const std::string& name) {
272 web_frame_->setReplicatedName(blink::WebString::fromUTF8(name));
273 }
274
270 void RenderFrameProxy::frameDetached() { 275 void RenderFrameProxy::frameDetached() {
271 if (web_frame_->parent()) 276 if (web_frame_->parent())
272 web_frame_->parent()->removeChild(web_frame_); 277 web_frame_->parent()->removeChild(web_frame_);
273 278
274 web_frame_->close(); 279 web_frame_->close();
275 delete this; 280 delete this;
276 } 281 }
277 282
278 void RenderFrameProxy::postMessageEvent( 283 void RenderFrameProxy::postMessageEvent(
279 blink::WebLocalFrame* source_frame, 284 blink::WebLocalFrame* source_frame,
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 blink::WebUserGestureIndicator::isProcessingUserGesture(); 331 blink::WebUserGestureIndicator::isProcessingUserGesture();
327 blink::WebUserGestureIndicator::consumeUserGesture(); 332 blink::WebUserGestureIndicator::consumeUserGesture();
328 Send(new FrameHostMsg_OpenURL(routing_id_, params)); 333 Send(new FrameHostMsg_OpenURL(routing_id_, params));
329 } 334 }
330 335
331 void RenderFrameProxy::forwardInputEvent(const blink::WebInputEvent* event) { 336 void RenderFrameProxy::forwardInputEvent(const blink::WebInputEvent* event) {
332 Send(new FrameHostMsg_ForwardInputEvent(routing_id_, event)); 337 Send(new FrameHostMsg_ForwardInputEvent(routing_id_, event));
333 } 338 }
334 339
335 } // namespace 340 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698