Index: chrome/common/chrome_content_client.cc |
diff --git a/chrome/common/chrome_content_client.cc b/chrome/common/chrome_content_client.cc |
index da07553e0035a9963a9ae744510393aca1742108..0d0252bc77aacb136f7c915963abc3b2b161c92e 100644 |
--- a/chrome/common/chrome_content_client.cc |
+++ b/chrome/common/chrome_content_client.cc |
@@ -51,6 +51,21 @@ const char kNaClPluginDescription[] = "Native Client Executable"; |
const char kNaClOldPluginName[] = "Chrome NaCl"; |
+#if defined(OS_POSIX) && !defined(OS_MACOSX) |
+const char kO3DPluginName[] = "Google Talk Plugin Video Accelerator"; |
+const char kO3DPluginMimeType[] ="application/vnd.o3d.auto"; |
+#if !defined(OS_CHROMEOS) |
+const char kGTO3DPluginMimeType[] = "application/vnd.gtpo3d.auto"; |
piman
2011/12/13 01:48:02
Do we really need different mime types? Can't we j
Josh Horwich
2011/12/13 22:06:30
Done. I've consolidated it to one MIME type now.
|
+#endif // !defined(CHROMEOS) |
+const char kO3DPluginExtension[] = ""; |
+const char kO3DPluginDescription[] = "O3D MIME"; |
+ |
+const char kGTalkPluginName[] = "Google Talk Plugin"; |
+const char kGTalkPluginMimeType[] ="application/googletalk"; |
+const char kGTalkPluginExtension[] = ".googletalk"; |
+const char kGTalkPluginDescription[] = "Google Talk Plugin"; |
+#endif // defined(OS_POSIX) && !defined(OS_MACOSX) |
+ |
#if defined(ENABLE_REMOTING) |
const char kRemotingViewerPluginName[] = "Remoting Viewer"; |
const FilePath::CharType kRemotingViewerPluginPath[] = |
@@ -117,6 +132,50 @@ void ComputeBuiltInPlugins(std::vector<content::PepperPluginInfo>* plugins) { |
} |
} |
+#if defined(OS_POSIX) && !defined(OS_MACOSX) |
+ static bool skip_o3d_file_check = false; |
+ if (PathService::Get(chrome::FILE_O3D_PLUGIN, &path)) { |
+ if (skip_o3d_file_check || file_util::PathExists(path)) { |
+ content::PepperPluginInfo o3d; |
+ o3d.path = path; |
+ o3d.name = kO3DPluginName; |
+ o3d.is_out_of_process = true; |
+ o3d.is_sandboxed = false; |
+ webkit::WebPluginMimeType o3d_mime_type(kO3DPluginMimeType, |
+ kO3DPluginExtension, |
+ kO3DPluginDescription); |
+ o3d.mime_types.push_back(o3d_mime_type); |
+#if !defined(OS_CHROMEOS) |
+ webkit::WebPluginMimeType gto3d_mime_type(kGTO3DPluginMimeType, |
+ kO3DPluginExtension, |
+ kO3DPluginDescription); |
+ o3d.mime_types.push_back(gto3d_mime_type); |
+#endif // !defined(OS_CHROMEOS) |
+ plugins->push_back(o3d); |
+ |
+ skip_o3d_file_check = true; |
+ } |
+ } |
+ |
+ static bool skip_gtalk_file_check = false; |
+ if (PathService::Get(chrome::FILE_GTALK_PLUGIN, &path)) { |
+ if (skip_gtalk_file_check || file_util::PathExists(path)) { |
+ content::PepperPluginInfo gtalk; |
+ gtalk.path = path; |
+ gtalk.name = kGTalkPluginName; |
+ gtalk.is_out_of_process = true; |
+ gtalk.is_sandboxed = false; |
+ webkit::WebPluginMimeType gtalk_mime_type(kGTalkPluginMimeType, |
+ kGTalkPluginExtension, |
+ kGTalkPluginDescription); |
+ gtalk.mime_types.push_back(gtalk_mime_type); |
+ plugins->push_back(gtalk); |
+ |
+ skip_gtalk_file_check = true; |
+ } |
+ } |
+#endif // defined(OS_POSIX) && !defined(OS_MACOSX) |
+ |
// The Remoting Viewer plugin is built-in. |
#if defined(ENABLE_REMOTING) |
content::PepperPluginInfo info; |