 Chromium Code Reviews
 Chromium Code Reviews Issue 1422473004:
  Vector-of-structs (instead of struct-of-vectors) in "savable resources" IPC.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@page-serialization-original-url-yay
    
  
    Issue 1422473004:
  Vector-of-structs (instead of struct-of-vectors) in "savable resources" IPC.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@page-serialization-original-url-yay| Index: content/renderer/web_frame_utils.cc | 
| diff --git a/content/renderer/web_frame_utils.cc b/content/renderer/web_frame_utils.cc | 
| new file mode 100644 | 
| index 0000000000000000000000000000000000000000..50e45e42ed3e2786bb76c8bbb4d69a67aedb750a | 
| --- /dev/null | 
| +++ b/content/renderer/web_frame_utils.cc | 
| @@ -0,0 +1,20 @@ | 
| +// Copyright 2015 The Chromium Authors. All rights reserved. | 
| +// Use of this source code is governed by a BSD-style license that can be | 
| +// found in the LICENSE file. | 
| + | 
| +#include "content/renderer/web_frame_utils.h" | 
| + | 
| +#include "content/renderer/render_frame_impl.h" | 
| +#include "content/renderer/render_frame_proxy.h" | 
| + | 
| +namespace content { | 
| + | 
| +int GetRoutingIdForFrameOrProxy(blink::WebFrame* web_frame) { | 
| + if (!web_frame) | 
| + return MSG_ROUTING_NONE; | 
| 
ncarter (slow)
2015/10/28 22:28:39
Need an #include for MSG_ROUTING_NONE
 
Łukasz Anforowicz
2015/10/28 23:12:06
Done.
 | 
| + if (web_frame->isWebRemoteFrame()) | 
| 
ncarter (slow)
2015/10/28 22:28:38
Need an #include for WebFrame.
 
Łukasz Anforowicz
2015/10/28 23:12:06
Done.
 | 
| + return RenderFrameProxy::FromWebFrame(web_frame)->routing_id(); | 
| + return RenderFrameImpl::FromWebFrame(web_frame)->GetRoutingID(); | 
| +} | 
| + | 
| +} // namespace content |