diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-16 15:48:24 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-16 15:48:24 +0000 |
commit | 0de85e7ef0cad4627c7a3bae9cb389087b242154 (patch) | |
tree | f83645726b5f55ca451fd02af44513d22b9773e5 /chrome/common/chrome_content_client.cc | |
parent | 73137ef6d22efe0c188c9401f7104e92722c0c66 (diff) | |
download | chromium_src-0de85e7ef0cad4627c7a3bae9cb389087b242154.zip chromium_src-0de85e7ef0cad4627c7a3bae9cb389087b242154.tar.gz chromium_src-0de85e7ef0cad4627c7a3bae9cb389087b242154.tar.bz2 |
Remove last dependencies on chrome\common from chrome\plugin.
TBR=avi
Review URL: http://codereview.chromium.org/6677064
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78372 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/chrome_content_client.cc')
-rw-r--r-- | chrome/common/chrome_content_client.cc | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/chrome/common/chrome_content_client.cc b/chrome/common/chrome_content_client.cc index 1c1b2d6..381c127 100644 --- a/chrome/common/chrome_content_client.cc +++ b/chrome/common/chrome_content_client.cc @@ -5,6 +5,15 @@ #include "chrome/common/chrome_content_client.h" #include "chrome/common/child_process_logging.h" +#include "chrome/common/default_plugin.h" + +#if defined(OS_MACOSX) +#include "base/mac/mac_util.h" +#include "base/mac/scoped_cftyperef.h" +#include "base/sys_string_conversions.h" +#include "grit/chromium_strings.h" +#include "ui/base/l10n/l10n_util.h" +#endif namespace chrome { @@ -16,7 +25,22 @@ void ChromeContentClient::SetGpuInfo(const GPUInfo& gpu_info) { child_process_logging::SetGpuInfo(gpu_info); } -void ChromeContentClient::PluginProcessStarted() { +void ChromeContentClient::PluginProcessStarted(const string16& plugin_name) { +#if defined(OS_MACOSX) + base::mac::ScopedCFTypeRef<CFStringRef> cf_plugin_name( + base::SysUTF16ToCFStringRef(plugin_name)); + base::mac::ScopedCFTypeRef<CFStringRef> app_name( + base::SysUTF16ToCFStringRef( + l10n_util::GetStringUTF16(IDS_SHORT_PLUGIN_APP_NAME))); + base::mac::ScopedCFTypeRef<CFStringRef> process_name( + CFStringCreateWithFormat(kCFAllocatorDefault, NULL, CFSTR("%@ (%@)"), + cf_plugin_name.get(), app_name.get())); + base::mac::SetProcessName(process_name); +#endif + +#if !defined(NACL_WIN64) // We don't link this in the NaCl 64 bit binary. + chrome::RegisterInternalDefaultPlugin(); +#endif } } // namespace chrome |