From fd49e2d9c6b9a294297c4cc79868e43e71df67ae Mon Sep 17 00:00:00 2001 From: "jhawkins@chromium.org" Date: Fri, 20 Feb 2009 17:21:30 +0000 Subject: Make plugin_service.cc compile on Posix. Review URL: http://codereview.chromium.org/20531 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10102 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/common/temp_scaffolding_stubs.h | 72 ++++++++++++++++++++-------------- 1 file changed, 43 insertions(+), 29 deletions(-) (limited to 'chrome/common/temp_scaffolding_stubs.h') diff --git a/chrome/common/temp_scaffolding_stubs.h b/chrome/common/temp_scaffolding_stubs.h index 8913a27..8f2adb8 100644 --- a/chrome/common/temp_scaffolding_stubs.h +++ b/chrome/common/temp_scaffolding_stubs.h @@ -9,6 +9,7 @@ // during the porting effort. It is not meant to be permanent, and classes will // be removed from here as they are fleshed out more completely. +#include #include #include "base/basictypes.h" @@ -39,6 +40,7 @@ #include "chrome/browser/renderer_host/render_view_host.h" #include "chrome/browser/renderer_host/render_widget_host.h" #include "chrome/browser/renderer_host/render_view_host_delegate.h" +#include "chrome/common/child_process_info.h" #include "chrome/common/navigation_types.h" #include "chrome/common/notification_service.h" #include "chrome/common/page_transition_types.h" @@ -48,6 +50,7 @@ #include "net/base/load_states.h" #include "skia/include/SkBitmap.h" #include "webkit/glue/password_form.h" +#include "webkit/glue/webplugin.h" #include "webkit/glue/window_open_disposition.h" class Browser; @@ -89,7 +92,6 @@ class UserScriptMaster; class VisitedLinkMaster; class WebContents; class WebContentsView; -struct WebPluginInfo; struct WebPluginGeometry; class WebPreferences; @@ -633,44 +635,56 @@ class PluginInstaller { PluginInstaller(WebContents*) { } }; -class PluginService { +class ChildProcessHost : public ChildProcessInfo { public: - static PluginService* GetInstance(); - PluginService(); - ~PluginService(); - void LoadChromePlugins(ResourceDispatcherHost* rdh) { + class Iterator { + public: + explicit Iterator(ProcessType type) { NOTIMPLEMENTED(); } + ChildProcessInfo* operator->() { return *iterator_; } + ChildProcessInfo* operator*() { return *iterator_; } + ChildProcessInfo* operator++() { return NULL; } + bool Done() { + NOTIMPLEMENTED(); + return true; + } + private: + std::list::iterator iterator_; + }; + protected: + ChildProcessHost(ProcessType type, MessageLoop* main_message_loop) + : ChildProcessInfo(type) { NOTIMPLEMENTED(); } - bool HavePluginFor(const std::string& mime_type, bool allow_wildcard) { +}; + +class PluginProcessHost : public ChildProcessHost { + public: + explicit PluginProcessHost(MessageLoop* main_message_loop) + : ChildProcessHost(PLUGIN_PROCESS, main_message_loop) { NOTIMPLEMENTED(); - return true; } - void SetChromePluginDataDir(const FilePath& data_dir); - FilePath GetChromePluginDataDir() { return chrome_plugin_data_dir_; } - void GetPlugins(bool reload, std::vector* plugins) {} - FilePath GetPluginPath(const GURL& url, - const std::string& mime_type, - const std::string& clsid, - std::string* actual_mime_type) { + bool Init(const WebPluginInfo& info, + const std::string& activex_clsid, + const std::wstring& locale) { NOTIMPLEMENTED(); - return FilePath(); + return false; } - void OpenChannelToPlugin(ResourceMessageFilter* renderer_msg_filter, - const GURL& url, + void OpenChannelToPlugin(ResourceMessageFilter* renderer_message_filter, const std::string& mime_type, - const std::string& clsid, - const std::wstring& locale, - IPC::Message* reply_msg) { NOTIMPLEMENTED(); } + IPC::Message* reply_msg) { + NOTIMPLEMENTED(); + } + static void ReplyToRenderer(ResourceMessageFilter* renderer_message_filter, + const std::wstring& channel, + const FilePath& plugin_path, + IPC::Message* reply_msg) { + NOTIMPLEMENTED(); + } void Shutdown() { NOTIMPLEMENTED(); } + const WebPluginInfo& info() const { return info_; } private: - MessageLoop* main_message_loop_; - ResourceDispatcherHost* resource_dispatcher_host_; - FilePath chrome_plugin_data_dir_; - std::wstring ui_locale_; - Lock lock_; - class ShutdownHandler : public base::RefCountedThreadSafe { - }; - scoped_refptr plugin_shutdown_handler_; + WebPluginInfo info_; + DISALLOW_EVIL_CONSTRUCTORS(PluginProcessHost); }; class HungRendererWarning { -- cgit v1.1