Changeset 126096 in webkit


Ignore:
Timestamp:
Aug 20, 2012 4:57:30 PM (12 years ago)
Author:
haraken@chromium.org
Message:

[V8] Remove V8Proxy from V8IsolatedContext
https://bugs.webkit.org/show_bug.cgi?id=94450

Reviewed by Adam Barth.

This patch removes dependency on V8Proxy from V8IsolatedContext.

No tests. No change in behavior.

  • bindings/v8/ScriptController.cpp:

(WebCore::ScriptController::evaluateInIsolatedWorld):

  • bindings/v8/V8IsolatedContext.cpp:

(WebCore::V8IsolatedContext::V8IsolatedContext):

  • bindings/v8/V8IsolatedContext.h:

(WebCore):
(V8IsolatedContext):

Location:
trunk/Source/WebCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r126094 r126096  
     12012-08-20  Kentaro Hara  <haraken@chromium.org>
     2
     3        [V8] Remove V8Proxy from V8IsolatedContext
     4        https://bugs.webkit.org/show_bug.cgi?id=94450
     5
     6        Reviewed by Adam Barth.
     7
     8        This patch removes dependency on V8Proxy from V8IsolatedContext.
     9
     10        No tests. No change in behavior.
     11
     12        * bindings/v8/ScriptController.cpp:
     13        (WebCore::ScriptController::evaluateInIsolatedWorld):
     14        * bindings/v8/V8IsolatedContext.cpp:
     15        (WebCore::V8IsolatedContext::V8IsolatedContext):
     16        * bindings/v8/V8IsolatedContext.h:
     17        (WebCore):
     18        (V8IsolatedContext):
     19
    1202012-08-20  Philip Rogers  <pdr@google.com>
    221
  • trunk/Source/WebCore/bindings/v8/ScriptController.cpp

    r126086 r126096  
    221221                isolatedContext = iter->second;
    222222            else {
    223                 isolatedContext = new V8IsolatedContext(proxy(), extensionGroup, worldID);
     223                isolatedContext = new V8IsolatedContext(m_frame, extensionGroup, worldID);
    224224                if (isolatedContext->context().IsEmpty()) {
    225225                    delete isolatedContext;
     
    235235                isolatedContext->setSecurityOrigin(securityOriginIter->second);
    236236        } else {
    237             isolatedContext = new V8IsolatedContext(proxy(), extensionGroup, worldID);
     237            isolatedContext = new V8IsolatedContext(m_frame, extensionGroup, worldID);
    238238            if (isolatedContext->context().IsEmpty()) {
    239239                delete isolatedContext;
  • trunk/Source/WebCore/bindings/v8/V8IsolatedContext.cpp

    r126066 r126096  
    3939#include "V8DOMWindow.h"
    4040#include "V8PerContextData.h"
    41 #include "V8Proxy.h"
    4241#include <wtf/StringExtras.h>
    4342
     
    6665}
    6766
    68 V8IsolatedContext::V8IsolatedContext(V8Proxy* proxy, int extensionGroup, int worldId)
     67V8IsolatedContext::V8IsolatedContext(Frame* frame, int extensionGroup, int worldId)
    6968    : m_world(IsolatedWorld::create(worldId)),
    70       m_frame(proxy->frame())
     69      m_frame(frame)
    7170{
    7271    v8::HandleScope scope;
    73     v8::Handle<v8::Context> mainWorldContext = proxy->windowShell()->context();
     72    v8::Handle<v8::Context> mainWorldContext = frame->script()->windowShell()->context();
    7473    if (mainWorldContext.IsEmpty())
    7574        return;
    7675
    7776    // FIXME: We should be creating a new V8DOMWindowShell here instead of riping out the context.
    78     m_context = SharedPersistent<v8::Context>::create(proxy->windowShell()->createNewContext(v8::Handle<v8::Object>(), extensionGroup, m_world->id()));
     77    m_context = SharedPersistent<v8::Context>::create(frame->script()->windowShell()->createNewContext(v8::Handle<v8::Object>(), extensionGroup, m_world->id()));
    7978    if (m_context->get().IsEmpty())
    8079        return;
     
    9190
    9291    // FIXME: This will go away once we have a windowShell for the isolated world.
    93     proxy->windowShell()->installDOMWindow(m_context->get(), m_frame->document()->domWindow());
     92    frame->script()->windowShell()->installDOMWindow(m_context->get(), m_frame->document()->domWindow());
    9493
    9594    // Using the default security token means that the canAccess is always
  • trunk/Source/WebCore/bindings/v8/V8IsolatedContext.h

    r126066 r126096  
    4040namespace WebCore {
    4141
     42class Frame;
    4243class SecurityOrigin;
    4344class V8PerContextData;
    44 class V8Proxy;
    4545
    4646// V8IsolatedContext
     
    6060    // Creates an isolated world. To destroy it, call destroy().
    6161    // This will delete the isolated world when the context it owns is GC'd.
    62     V8IsolatedContext(V8Proxy*, int extensionGroup, int worldId);
     62    V8IsolatedContext(Frame*, int extensionGroup, int worldId);
    6363    ~V8IsolatedContext();
    6464
Note: See TracChangeset for help on using the changeset viewer.