Home | History | Annotate | Download | only in test
      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
      3 // found in the LICENSE file.
      4 
      5 #include "content/test/test_render_frame_host_factory.h"
      6 
      7 #include "base/basictypes.h"
      8 #include "base/compiler_specific.h"
      9 #include "base/logging.h"
     10 #include "content/test/test_render_frame_host.h"
     11 
     12 namespace content {
     13 
     14 TestRenderFrameHostFactory::TestRenderFrameHostFactory() {
     15   RenderFrameHostFactory::RegisterFactory(this);
     16 }
     17 
     18 TestRenderFrameHostFactory::~TestRenderFrameHostFactory() {
     19   RenderFrameHostFactory::UnregisterFactory();
     20 }
     21 
     22 scoped_ptr<RenderFrameHostImpl>
     23 TestRenderFrameHostFactory::CreateRenderFrameHost(
     24     RenderViewHostImpl* render_view_host,
     25     RenderFrameHostDelegate* delegate,
     26     FrameTree* frame_tree,
     27     FrameTreeNode* frame_tree_node,
     28     int routing_id,
     29     bool is_swapped_out) {
     30   return make_scoped_ptr(
     31       new TestRenderFrameHost(
     32           render_view_host, delegate, frame_tree, frame_tree_node, routing_id,
     33           is_swapped_out))
     34       .PassAs<RenderFrameHostImpl>();
     35 }
     36 
     37 }  // namespace content
     38