diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 20:42:39 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 20:42:39 +0000 |
commit | a82151cc51eab71162a356a8b9f83885d9386ef8 (patch) | |
tree | c2fe49e664055bec7dd216555773f38d4ce9bc9c /chrome | |
parent | e811162117c95c46d555d5241f68f6e8378fc391 (diff) | |
download | chromium_src-a82151cc51eab71162a356a8b9f83885d9386ef8.zip chromium_src-a82151cc51eab71162a356a8b9f83885d9386ef8.tar.gz chromium_src-a82151cc51eab71162a356a8b9f83885d9386ef8.tar.bz2 |
Get rid of some more dependencies on chrome\common from plugin, in preparation for moving the plugin directory to content.
TBR=avi
Review URL: http://codereview.chromium.org/6677053
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78278 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/chrome_common.gypi | 2 | ||||
-rw-r--r-- | chrome/common/chrome_content_client.cc | 1 | ||||
-rw-r--r-- | chrome/common/plugin_carbon_interpose_constants_mac.cc | 17 | ||||
-rw-r--r-- | chrome/common/plugin_carbon_interpose_constants_mac.h | 21 | ||||
-rw-r--r-- | chrome/plugin/npobject_stub.cc | 6 | ||||
-rw-r--r-- | chrome/plugin/plugin_main_mac.mm | 2 | ||||
-rw-r--r-- | chrome/plugin/webplugin_delegate_stub.cc | 8 | ||||
-rw-r--r-- | chrome/plugin/webplugin_proxy.cc | 11 |
8 files changed, 14 insertions, 54 deletions
diff --git a/chrome/chrome_common.gypi b/chrome/chrome_common.gypi index 44b6eed..485057c 100644 --- a/chrome/chrome_common.gypi +++ b/chrome/chrome_common.gypi @@ -246,8 +246,6 @@ 'common/page_zoom.h', 'common/pepper_plugin_registry.cc', 'common/pepper_plugin_registry.h', - 'common/plugin_carbon_interpose_constants_mac.cc', - 'common/plugin_carbon_interpose_constants_mac.h', 'common/persistent_pref_store.h', 'common/pref_store.cc', 'common/pref_store.h', diff --git a/chrome/common/chrome_content_client.cc b/chrome/common/chrome_content_client.cc index 7e53a77..1c1b2d6 100644 --- a/chrome/common/chrome_content_client.cc +++ b/chrome/common/chrome_content_client.cc @@ -9,6 +9,7 @@ namespace chrome { void ChromeContentClient::SetActiveURL(const GURL& url) { + child_process_logging::SetActiveURL(url); } void ChromeContentClient::SetGpuInfo(const GPUInfo& gpu_info) { diff --git a/chrome/common/plugin_carbon_interpose_constants_mac.cc b/chrome/common/plugin_carbon_interpose_constants_mac.cc deleted file mode 100644 index d7f6f91..0000000 --- a/chrome/common/plugin_carbon_interpose_constants_mac.cc +++ /dev/null @@ -1,17 +0,0 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#if !defined(__LP64__) - -#include "chrome/common/plugin_carbon_interpose_constants_mac.h" - -namespace plugin_interpose_strings { - -const char kDYLDInsertLibrariesKey[] = "DYLD_INSERT_LIBRARIES"; -const char kInterposeLibraryPath[] = - "@executable_path/libplugin_carbon_interpose.dylib"; - -} // namespace plugin_interpose_strings - -#endif // !__LP64__ diff --git a/chrome/common/plugin_carbon_interpose_constants_mac.h b/chrome/common/plugin_carbon_interpose_constants_mac.h deleted file mode 100644 index 967da77..0000000 --- a/chrome/common/plugin_carbon_interpose_constants_mac.h +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CHROME_COMMON_PLUGIN_CARBON_INTERPOSE_CONSTANTS_MAC_H_ -#define CHROME_COMMON_PLUGIN_CARBON_INTERPOSE_CONSTANTS_MAC_H_ -#pragma once - -#if !defined(__LP64__) - -// Strings used in setting up Carbon interposing for the plugin process. -namespace plugin_interpose_strings { - -extern const char kDYLDInsertLibrariesKey[]; -extern const char kInterposeLibraryPath[]; - -} // namespace plugin_interpose_strings - -#endif // !__LP64__ - -#endif // CHROME_BROWSER_PLUGIN_CARBON_INTERPOSE_CONSTANTS_MAC_H_ diff --git a/chrome/plugin/npobject_stub.cc b/chrome/plugin/npobject_stub.cc index 128b7da..eae17b6 100644 --- a/chrome/plugin/npobject_stub.cc +++ b/chrome/plugin/npobject_stub.cc @@ -1,13 +1,13 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chrome/plugin/npobject_stub.h" -#include "chrome/common/child_process_logging.h" #include "chrome/plugin/npobject_util.h" #include "chrome/plugin/plugin_channel_base.h" #include "chrome/plugin/plugin_thread.h" +#include "content/common/content_client.h" #include "content/common/plugin_messages.h" #include "third_party/npapi/bindings/npapi.h" #include "third_party/npapi/bindings/npruntime.h" @@ -63,7 +63,7 @@ IPC::Channel::Listener* NPObjectStub::GetChannelListener() { } bool NPObjectStub::OnMessageReceived(const IPC::Message& msg) { - child_process_logging::SetActiveURL(page_url_); + content::GetContentClient()->SetActiveURL(page_url_); if (!npobject_) { if (msg.is_sync()) { diff --git a/chrome/plugin/plugin_main_mac.mm b/chrome/plugin/plugin_main_mac.mm index 122dc39..22283d83 100644 --- a/chrome/plugin/plugin_main_mac.mm +++ b/chrome/plugin/plugin_main_mac.mm @@ -5,9 +5,9 @@ #include "base/environment.h" #include "base/scoped_ptr.h" #include "base/string_util.h" -#include "chrome/common/plugin_carbon_interpose_constants_mac.h" #include "chrome/plugin/plugin_interpose_util_mac.h" #include "content/common/chrome_application_mac.h" +#include "content/common/plugin_carbon_interpose_constants_mac.h" #if !defined(__LP64__) void TrimInterposeEnvironment() { diff --git a/chrome/plugin/webplugin_delegate_stub.cc b/chrome/plugin/webplugin_delegate_stub.cc index bf58a96..e404b1e 100644 --- a/chrome/plugin/webplugin_delegate_stub.cc +++ b/chrome/plugin/webplugin_delegate_stub.cc @@ -7,12 +7,12 @@ #include "build/build_config.h" #include "base/command_line.h" -#include "chrome/common/child_process_logging.h" #include "chrome/common/chrome_switches.h" #include "chrome/plugin/npobject_stub.h" #include "chrome/plugin/plugin_channel.h" #include "chrome/plugin/plugin_thread.h" #include "chrome/plugin/webplugin_proxy.h" +#include "content/common/content_client.h" #include "content/common/plugin_messages.h" #include "third_party/npapi/bindings/npapi.h" #include "third_party/npapi/bindings/npruntime.h" @@ -66,7 +66,7 @@ WebPluginDelegateStub::WebPluginDelegateStub( WebPluginDelegateStub::~WebPluginDelegateStub() { in_destructor_ = true; - child_process_logging::SetActiveURL(page_url_); + content::GetContentClient()->SetActiveURL(page_url_); if (channel_->in_send()) { // The delegate or an npobject is in the callstack, so don't delete it @@ -83,7 +83,7 @@ WebPluginDelegateStub::~WebPluginDelegateStub() { } bool WebPluginDelegateStub::OnMessageReceived(const IPC::Message& msg) { - child_process_logging::SetActiveURL(page_url_); + content::GetContentClient()->SetActiveURL(page_url_); // A plugin can execute a script to delete itself in any of its NPP methods. // Hold an extra reference to ourself so that if this does occur and we're @@ -154,7 +154,7 @@ bool WebPluginDelegateStub::Send(IPC::Message* msg) { void WebPluginDelegateStub::OnInit(const PluginMsg_Init_Params& params, bool* result) { page_url_ = params.page_url; - child_process_logging::SetActiveURL(page_url_); + content::GetContentClient()->SetActiveURL(page_url_); *result = false; if (params.arg_names.size() != params.arg_values.size()) { diff --git a/chrome/plugin/webplugin_proxy.cc b/chrome/plugin/webplugin_proxy.cc index e1101e0..bc223dd 100644 --- a/chrome/plugin/webplugin_proxy.cc +++ b/chrome/plugin/webplugin_proxy.cc @@ -10,12 +10,11 @@ #include "base/scoped_handle.h" #include "base/shared_memory.h" #include "build/build_config.h" -#include "chrome/common/child_process_logging.h" -#include "chrome/common/url_constants.h" #include "chrome/plugin/npobject_proxy.h" #include "chrome/plugin/npobject_util.h" #include "chrome/plugin/plugin_channel.h" #include "chrome/plugin/plugin_thread.h" +#include "content/common/content_client.h" #include "content/common/plugin_messages.h" #include "skia/ext/platform_device.h" #include "third_party/WebKit/Source/WebKit/chromium/public/WebBindings.h" @@ -290,9 +289,9 @@ void WebPluginProxy::HandleURLRequest(const char* url, webkit::npapi::WebPluginDelegateImpl:: PLUGIN_QUIRK_BLOCK_NONSTANDARD_GETURL_REQUESTS) { GURL request_url(url); - if (!request_url.SchemeIs(chrome::kHttpScheme) && - !request_url.SchemeIs(chrome::kHttpsScheme) && - !request_url.SchemeIs(chrome::kFtpScheme)) { + if (!request_url.SchemeIs("http") && + !request_url.SchemeIs("https") && + !request_url.SchemeIs("ftp")) { return; } } @@ -628,7 +627,7 @@ void WebPluginProxy::FreeSurfaceDIB(TransportDIB::Id dib_id) { #endif void WebPluginProxy::OnPaint(const gfx::Rect& damaged_rect) { - child_process_logging::SetActiveURL(page_url_); + content::GetContentClient()->SetActiveURL(page_url_); Paint(damaged_rect); Send(new PluginHostMsg_InvalidateRect(route_id_, damaged_rect)); |