diff options
author | aa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-04 15:04:04 +0000 |
---|---|---|
committer | aa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-04 15:04:04 +0000 |
commit | 2ee1e3afa96495070273b36ed938872318eb0dac (patch) | |
tree | 6e2552cf4d05fb8bda8dd7b7cf28f46504a0fcfc /chrome/renderer/chrome_content_renderer_client.cc | |
parent | b19537cdc317d6baab5183e111668ccc88c661f6 (diff) | |
download | chromium_src-2ee1e3afa96495070273b36ed938872318eb0dac.zip chromium_src-2ee1e3afa96495070273b36ed938872318eb0dac.tar.gz chromium_src-2ee1e3afa96495070273b36ed938872318eb0dac.tar.bz2 |
Factor the static data and its management out of
ExtensionBindingsContext into ExtensionBindingsContextSet.
Add a unit test (!!).
Review URL: http://codereview.chromium.org/8093017
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@103887 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/chrome_content_renderer_client.cc')
-rw-r--r-- | chrome/renderer/chrome_content_renderer_client.cc | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/chrome/renderer/chrome_content_renderer_client.cc b/chrome/renderer/chrome_content_renderer_client.cc index 39a108a..9ec1ceb 100644 --- a/chrome/renderer/chrome_content_renderer_client.cc +++ b/chrome/renderer/chrome_content_renderer_client.cc @@ -7,7 +7,7 @@ #include <string> #include "base/command_line.h" -#include "base/message_loop.h" +#include "base/logging.h" #include "base/metrics/histogram.h" #include "base/path_service.h" #include "base/utf_string_conversions.h" @@ -581,7 +581,7 @@ bool ChromeContentRendererClient::AllowPopup(const GURL& creator) { // Extensions and apps always allowed to create unrequested popups. The second // check is necessary to include content scripts. return extension_dispatcher_->extensions()->GetByURL(creator) || - ExtensionBindingsContext::GetCurrent(); + extension_dispatcher_->bindings_context_set().GetCurrent(); } bool ChromeContentRendererClient::ShouldFork(WebFrame* frame, @@ -645,19 +645,12 @@ bool ChromeContentRendererClient::ShouldPumpEventsDuringCookieMessage() { void ChromeContentRendererClient::DidCreateScriptContext( WebFrame* frame, v8::Handle<v8::Context> context, int world_id) { - ExtensionBindingsContext::HandleV8ContextCreated( - frame, - context, - extension_dispatcher_.get(), - world_id); + extension_dispatcher_->DidCreateScriptContext(frame, context, world_id); } void ChromeContentRendererClient::WillReleaseScriptContext( WebFrame* frame, v8::Handle<v8::Context> context, int world_id) { - ExtensionBindingsContext::HandleV8ContextReleased( - frame, - context, - world_id); + extension_dispatcher_->WillReleaseScriptContext(frame, context, world_id); } unsigned long long ChromeContentRendererClient::VisitedLinkHash( |