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

Side by Side Diff: content/test/test_render_frame_host_factory.h

Issue 103633002: Add RenderFrameHostDelegate and plumb it through all the necessary classes. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years 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 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_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_ 5 #ifndef CONTENT_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_
6 #define CONTENT_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_ 6 #define CONTENT_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "content/browser/frame_host/render_frame_host_factory.h" 11 #include "content/browser/frame_host/render_frame_host_factory.h"
12 12
13 namespace content { 13 namespace content {
14 14
15 class FrameTree;
16 class RenderFrameHostImpl;
17 class RenderViewHostImpl;
18
19 // Manages creation of the RenderFrameHostImpls; when registered, all created 15 // Manages creation of the RenderFrameHostImpls; when registered, all created
20 // RenderFrameHostsImpls will be TestRenderFrameHosts. This 16 // RenderFrameHostsImpls will be TestRenderFrameHosts. This
21 // automatically registers itself when it goes in scope, and unregisters itself 17 // automatically registers itself when it goes in scope, and unregisters itself
22 // when it goes out of scope. Since you can't have more than one factory 18 // when it goes out of scope. Since you can't have more than one factory
23 // registered at a time, you can only have one of these objects at a time. 19 // registered at a time, you can only have one of these objects at a time.
24 class TestRenderFrameHostFactory : public RenderFrameHostFactory { 20 class TestRenderFrameHostFactory : public RenderFrameHostFactory {
25 public: 21 public:
26 TestRenderFrameHostFactory(); 22 TestRenderFrameHostFactory();
27 virtual ~TestRenderFrameHostFactory(); 23 virtual ~TestRenderFrameHostFactory();
28 24
29 protected: 25 protected:
30 // RenderFrameHostFactory implementation. 26 // RenderFrameHostFactory implementation.
31 virtual scoped_ptr<RenderFrameHostImpl> CreateRenderFrameHost( 27 virtual scoped_ptr<RenderFrameHostImpl> CreateRenderFrameHost(
32 RenderViewHostImpl* render_view_host, 28 RenderViewHostImpl* render_view_host,
29 RenderFrameHostDelegate* delegate,
33 FrameTree* frame_tree, 30 FrameTree* frame_tree,
34 int routing_id, 31 int routing_id,
35 bool is_swapped_out) OVERRIDE; 32 bool is_swapped_out) OVERRIDE;
36 33
37 private: 34 private:
38 DISALLOW_COPY_AND_ASSIGN(TestRenderFrameHostFactory); 35 DISALLOW_COPY_AND_ASSIGN(TestRenderFrameHostFactory);
39 }; 36 };
40 37
41 } // namespace content 38 } // namespace content
42 39
43 #endif // CONTENT_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_ 40 #endif // CONTENT_TEST_TEST_RENDER_FRAME_HOST_FACTORY_H_
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_impl_unittest.cc ('k') | content/test/test_render_frame_host_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698