Skip to content
Permalink
Browse files
[chromium] Plumb extensionGroup into didCreateScriptContext().
https://bugs.webkit.org/show_bug.cgi?id=79072

Reviewed by Darin Fisher.

Source/WebCore:

* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::initContextIfNeeded):
* bindings/v8/V8IsolatedContext.cpp:
(WebCore::V8IsolatedContext::V8IsolatedContext):
* loader/EmptyClients.h:
(WebCore::EmptyFrameLoaderClient::didCreateScriptContext):
* loader/FrameLoaderClient.h:
(FrameLoaderClient):

Source/WebKit/chromium:

* public/WebFrameClient.h:
(WebKit::WebFrameClient::didCreateScriptContext):
* src/FrameLoaderClientImpl.cpp:
(WebKit::FrameLoaderClientImpl::didCreateScriptContext):
* src/FrameLoaderClientImpl.h:
(FrameLoaderClientImpl):


Canonical link: https://commits.webkit.org/96826@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@109064 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
James Kozianski committed Feb 28, 2012
1 parent e67093b commit 63777168cdc252f0d4044c45298d38f68a17f814
@@ -1,3 +1,19 @@
2012-02-27 James Kozianski <koz@chromium.org>

[chromium] Plumb extensionGroup into didCreateScriptContext().
https://bugs.webkit.org/show_bug.cgi?id=79072

Reviewed by Darin Fisher.

* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::initContextIfNeeded):
* bindings/v8/V8IsolatedContext.cpp:
(WebCore::V8IsolatedContext::V8IsolatedContext):
* loader/EmptyClients.h:
(WebCore::EmptyFrameLoaderClient::didCreateScriptContext):
* loader/FrameLoaderClient.h:
(FrameLoaderClient):

2012-02-27 Huang Dongsung <luxtella@company100.net>

Fixed a typo in CanvasRenderingContext2D::drawImage(HTMLCanvasElement);
@@ -339,7 +339,7 @@ bool V8DOMWindowShell::initContextIfNeeded()

setSecurityToken();

m_frame->loader()->client()->didCreateScriptContext(m_context, 0);
m_frame->loader()->client()->didCreateScriptContext(m_context, 0, 0);

// FIXME: This is wrong. We should actually do this for the proper world once
// we do isolated worlds the WebCore way.
@@ -75,7 +75,7 @@ V8IsolatedContext::V8IsolatedContext(V8Proxy* proxy, int extensionGroup, int wor
// changes.
m_context->get()->UseDefaultSecurityToken();

m_frame->loader()->client()->didCreateScriptContext(context(), m_world->id());
m_frame->loader()->client()->didCreateScriptContext(context(), extensionGroup, m_world->id());
}

void V8IsolatedContext::destroy()
@@ -394,7 +394,7 @@ class EmptyFrameLoaderClient : public FrameLoaderClient {
virtual void registerForIconNotification(bool) { }

#if USE(V8)
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int worldId) { }
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int extensionGroup, int worldId) { }
virtual void willReleaseScriptContext(v8::Handle<v8::Context>, int worldId) { }
virtual bool allowScriptExtension(const String& extensionName, int extensionGroup, int worldId) { return false; }
#endif
@@ -280,7 +280,7 @@ namespace WebCore {
virtual void didPerformFirstNavigation() const = 0; // "Navigation" here means a transition from one page to another that ends up in the back/forward list.

#if USE(V8)
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int worldId) = 0;
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int extensionGroup, int worldId) = 0;
virtual void willReleaseScriptContext(v8::Handle<v8::Context>, int worldId) = 0;
virtual bool allowScriptExtension(const String& extensionName, int extensionGroup, int worldId) = 0;
#endif
@@ -1,3 +1,17 @@
2012-02-27 James Kozianski <koz@chromium.org>

[chromium] Plumb extensionGroup into didCreateScriptContext().
https://bugs.webkit.org/show_bug.cgi?id=79072

Reviewed by Darin Fisher.

* public/WebFrameClient.h:
(WebKit::WebFrameClient::didCreateScriptContext):
* src/FrameLoaderClientImpl.cpp:
(WebKit::FrameLoaderClientImpl::didCreateScriptContext):
* src/FrameLoaderClientImpl.h:
(FrameLoaderClientImpl):

2012-02-27 Adrienne Walker <enne@google.com>

[chromium] Unreviewed gardening, disable TransparencyWinTest unit tests
@@ -297,7 +297,7 @@ class WebFrameClient {
// Notifies that a new script context has been created for this frame.
// This is similar to didClearWindowObject but only called once per
// frame context.
virtual void didCreateScriptContext(WebFrame*, v8::Handle<v8::Context>, int worldId) { }
virtual void didCreateScriptContext(WebFrame*, v8::Handle<v8::Context>, int extensionGroup, int worldId) { }

// WebKit is about to release its reference to a v8 context for a frame.
virtual void willReleaseScriptContext(WebFrame*, v8::Handle<v8::Context>, int worldId) { }
@@ -145,10 +145,10 @@ void FrameLoaderClientImpl::documentElementAvailable()
}

#if USE(V8)
void FrameLoaderClientImpl::didCreateScriptContext(v8::Handle<v8::Context> context, int worldId)
void FrameLoaderClientImpl::didCreateScriptContext(v8::Handle<v8::Context> context, int extensionGroup, int worldId)
{
if (m_webFrame->client())
m_webFrame->client()->didCreateScriptContext(m_webFrame, context, worldId);
m_webFrame->client()->didCreateScriptContext(m_webFrame, context, extensionGroup, worldId);
}

void FrameLoaderClientImpl::willReleaseScriptContext(v8::Handle<v8::Context> context, int worldId)
@@ -62,7 +62,7 @@ class FrameLoaderClientImpl : public WebCore::FrameLoaderClient {
virtual void documentElementAvailable();

#if USE(V8)
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int worldId);
virtual void didCreateScriptContext(v8::Handle<v8::Context>, int extensionGroup, int worldId);
virtual void willReleaseScriptContext(v8::Handle<v8::Context>, int worldId);
#endif

0 comments on commit 6377716

Please sign in to comment.