1 // Copyright (c) 2012 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 #ifndef CONTENT_SHELL_SHELL_CONTENT_RENDERER_CLIENT_H_ 6 #define CONTENT_SHELL_SHELL_CONTENT_RENDERER_CLIENT_H_ 7 8 #include "base/compiler_specific.h" 9 #include "base/memory/scoped_ptr.h" 10 #include "content/public/renderer/content_renderer_client.h" 11 12 namespace blink { 13 class WebFrame; 14 class WebPlugin; 15 struct WebPluginParams; 16 } 17 18 namespace content { 19 20 class MockWebClipboardImpl; 21 class ShellRenderProcessObserver; 22 class WebTestProxyBase; 23 24 class ShellContentRendererClient : public ContentRendererClient { 25 public: 26 ShellContentRendererClient(); 27 virtual ~ShellContentRendererClient(); 28 29 // ContentRendererClient implementation. 30 virtual void RenderThreadStarted() OVERRIDE; 31 virtual void RenderFrameCreated(RenderFrame* render_frame) OVERRIDE; 32 virtual void RenderViewCreated(RenderView* render_view) OVERRIDE; 33 virtual bool OverrideCreatePlugin( 34 RenderFrame* render_frame, 35 blink::WebLocalFrame* frame, 36 const blink::WebPluginParams& params, 37 blink::WebPlugin** plugin) OVERRIDE; 38 virtual blink::WebMediaStreamCenter* OverrideCreateWebMediaStreamCenter( 39 blink::WebMediaStreamCenterClient* client) OVERRIDE; 40 virtual blink::WebRTCPeerConnectionHandler* 41 OverrideCreateWebRTCPeerConnectionHandler( 42 blink::WebRTCPeerConnectionHandlerClient* client) OVERRIDE; 43 virtual blink::WebMIDIAccessor* OverrideCreateMIDIAccessor( 44 blink::WebMIDIAccessorClient* client) OVERRIDE; 45 virtual blink::WebAudioDevice* OverrideCreateAudioDevice( 46 double sample_rate) OVERRIDE; 47 virtual blink::WebClipboard* OverrideWebClipboard() OVERRIDE; 48 virtual blink::WebThemeEngine* OverrideThemeEngine() OVERRIDE; 49 50 private: 51 void WebTestProxyCreated(RenderView* render_view, WebTestProxyBase* proxy); 52 53 scoped_ptr<ShellRenderProcessObserver> shell_observer_; 54 scoped_ptr<MockWebClipboardImpl> clipboard_; 55 }; 56 57 } // namespace content 58 59 #endif // CONTENT_SHELL_SHELL_CONTENT_RENDERER_CLIENT_H_ 60