<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[165914] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/165914">165914</a></dd>
<dt>Author</dt> <dd>akling@apple.com</dd>
<dt>Date</dt> <dd>2014-03-19 13:42:55 -0700 (Wed, 19 Mar 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>JSC bindings should use the passed-in global object for wrapper caching.
&lt;https://webkit.org/b/130458&gt;

Take a shorter path to the DOMWrapperWorld by using the passed-in
global object instead of getting the lexical global from ExecState.
Removed an old FIXME that no longer applies since JSObjects can
always find the right global object these days.

Reviewed by Geoff Garen.

* bindings/js/JSCSSRuleCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCSSStyleDeclarationCustom.cpp:
(WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
* bindings/js/JSCSSValueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSDOMBinding.h:
(WebCore::createWrapper):
(WebCore::wrap):
(WebCore::getExistingWrapper):
(WebCore::createNewWrapper):
(WebCore::toJS):
* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::JSDOMWindow::setTimeout):
(WebCore::JSDOMWindow::setInterval):
(WebCore::JSDOMWindow::addEventListener):
(WebCore::JSDOMWindow::removeEventListener):
* bindings/js/JSDocumentCustom.cpp:
(WebCore::JSDocument::location):
(WebCore::toJS):
* bindings/js/JSElementCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSEventCustom.cpp:
(WebCore::toJS):
* bindings/js/JSHTMLCollectionCustom.cpp:
(WebCore::toJS):
* bindings/js/JSHTMLTemplateElementCustom.cpp:
(WebCore::JSHTMLTemplateElement::content):
* bindings/js/JSImageDataCustom.cpp:
(WebCore::toJS):
* bindings/js/JSNodeCustom.cpp:
(WebCore::createWrapperInline):
* bindings/js/JSNodeCustom.h:
(WebCore::toJS):
* bindings/js/JSSVGPathSegCustom.cpp:
(WebCore::toJS):
* bindings/js/JSStyleSheetCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTextTrackCueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTrackCustom.cpp:
(WebCore::toJS):
* bindings/js/JSWorkerGlobalScopeCustom.cpp:
(WebCore::JSWorkerGlobalScope::setTimeout):
(WebCore::JSWorkerGlobalScope::setInterval):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSRuleCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSStyleDeclarationCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSValueCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMBindingh">trunk/Source/WebCore/bindings/js/JSDOMBinding.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMWindowCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDocumentCustomcpp">trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSElementCustomcpp">trunk/Source/WebCore/bindings/js/JSElementCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSEventCustomcpp">trunk/Source/WebCore/bindings/js/JSEventCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLTemplateElementCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSImageDataCustomcpp">trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeCustomcpp">trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeCustomh">trunk/Source/WebCore/bindings/js/JSNodeCustom.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSSVGPathSegCustomcpp">trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSStyleSheetCustomcpp">trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp">trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTrackCustomcpp">trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSWorkerGlobalScopeCustomcpp">trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm">trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/ChangeLog        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -1,3 +1,63 @@
</span><ins>+2014-03-19  Andreas Kling  &lt;akling@apple.com&gt;
+
+        JSC bindings should use the passed-in global object for wrapper caching.
+        &lt;https://webkit.org/b/130458&gt;
+
+        Take a shorter path to the DOMWrapperWorld by using the passed-in
+        global object instead of getting the lexical global from ExecState.
+        Removed an old FIXME that no longer applies since JSObjects can
+        always find the right global object these days.
+
+        Reviewed by Geoff Garen.
+
+        * bindings/js/JSCSSRuleCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
+        (WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
+        * bindings/js/JSCSSValueCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSDOMBinding.h:
+        (WebCore::createWrapper):
+        (WebCore::wrap):
+        (WebCore::getExistingWrapper):
+        (WebCore::createNewWrapper):
+        (WebCore::toJS):
+        * bindings/js/JSDOMWindowCustom.cpp:
+        (WebCore::JSDOMWindow::setTimeout):
+        (WebCore::JSDOMWindow::setInterval):
+        (WebCore::JSDOMWindow::addEventListener):
+        (WebCore::JSDOMWindow::removeEventListener):
+        * bindings/js/JSDocumentCustom.cpp:
+        (WebCore::JSDocument::location):
+        (WebCore::toJS):
+        * bindings/js/JSElementCustom.cpp:
+        (WebCore::toJSNewlyCreated):
+        * bindings/js/JSEventCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSHTMLCollectionCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSHTMLTemplateElementCustom.cpp:
+        (WebCore::JSHTMLTemplateElement::content):
+        * bindings/js/JSImageDataCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSNodeCustom.cpp:
+        (WebCore::createWrapperInline):
+        * bindings/js/JSNodeCustom.h:
+        (WebCore::toJS):
+        * bindings/js/JSSVGPathSegCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSStyleSheetCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSTextTrackCueCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSTrackCustom.cpp:
+        (WebCore::toJS):
+        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
+        (WebCore::JSWorkerGlobalScope::setTimeout):
+        (WebCore::JSWorkerGlobalScope::setInterval):
+        * bindings/scripts/CodeGeneratorJS.pm:
+        (GenerateImplementation):
+
</ins><span class="cx"> 2014-03-19  Benjamin Poulain  &lt;bpoulain@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Page::setPageScaleFactor should not force the scroll view position when using delegatesScrolling()
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSRuleCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -70,7 +70,7 @@
</span><span class="cx">     if (!rule)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), rule);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), rule);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSStyleDeclarationCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -376,7 +376,7 @@
</span><span class="cx">     if (!cssValue)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    currentWorld(exec).m_cssValueRoots.add(cssValue.get(), root(&amp;impl())); // Balanced by JSCSSValueOwner::finalize().
</del><ins>+    globalObject()-&gt;world().m_cssValueRoots.add(cssValue.get(), root(&amp;impl())); // Balanced by JSCSSValueOwner::finalize().
</ins><span class="cx">     return toJS(exec, globalObject(), WTF::getPtr(cssValue));
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSValueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -80,7 +80,7 @@
</span><span class="cx">     if (!value-&gt;isCSSOMSafe())
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), value);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), value);
</ins><span class="cx"> 
</span><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMBindingh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMBinding.h (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMBinding.h        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSDOMBinding.h        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -199,11 +199,9 @@
</span><span class="cx"> template&lt;class WrapperClass, class DOMClass&gt; inline JSDOMWrapper* createWrapper(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, DOMClass* node)
</span><span class="cx"> {
</span><span class="cx">     ASSERT(node);
</span><del>-    ASSERT(!getCachedWrapper(currentWorld(exec), node));
</del><ins>+    ASSERT(!getCachedWrapper(globalObject-&gt;world(), node));
</ins><span class="cx">     WrapperClass* wrapper = WrapperClass::create(getDOMStructure&lt;WrapperClass&gt;(exec-&gt;vm(), globalObject), globalObject, node);
</span><del>-    // FIXME: The entire function can be removed, once we fix caching.
-    // This function is a one-off hack to make Nodes cache in the right global object.
-    cacheWrapper(currentWorld(exec), node, wrapper);
</del><ins>+    cacheWrapper(globalObject-&gt;world(), node, wrapper);
</ins><span class="cx">     return wrapper;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -211,21 +209,21 @@
</span><span class="cx"> {
</span><span class="cx">     if (!domObject)
</span><span class="cx">         return JSC::jsNull();
</span><del>-    if (JSC::JSObject* wrapper = getCachedWrapper(currentWorld(exec), domObject))
</del><ins>+    if (JSC::JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), domObject))
</ins><span class="cx">         return wrapper;
</span><span class="cx">     return createWrapper&lt;WrapperClass&gt;(exec, globalObject, domObject);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-template&lt;class WrapperClass, class DOMClass&gt; inline JSC::JSValue getExistingWrapper(JSC::ExecState* exec, DOMClass* domObject)
</del><ins>+template&lt;class WrapperClass, class DOMClass&gt; inline JSC::JSValue getExistingWrapper(JSDOMGlobalObject* globalObject, DOMClass* domObject)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(domObject);
</span><del>-    return getCachedWrapper(currentWorld(exec), domObject);
</del><ins>+    return getCachedWrapper(globalObject-&gt;world(), domObject);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template&lt;class WrapperClass, class DOMClass&gt; inline JSC::JSValue createNewWrapper(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, DOMClass* domObject)
</span><span class="cx"> {
</span><span class="cx">     ASSERT(domObject);
</span><del>-    ASSERT(!getCachedWrapper(currentWorld(exec), domObject));
</del><ins>+    ASSERT(!getCachedWrapper(globalObject-&gt;world(), domObject));
</ins><span class="cx">     return createWrapper&lt;WrapperClass&gt;(exec, globalObject, domObject);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -348,11 +346,11 @@
</span><span class="cx"> {
</span><span class="cx">     if (!buffer)
</span><span class="cx">         return JSC::jsNull();
</span><del>-    if (JSC::JSValue result = getExistingWrapper&lt;JSC::JSArrayBuffer&gt;(exec, buffer))
</del><ins>+    if (JSC::JSValue result = getExistingWrapper&lt;JSC::JSArrayBuffer&gt;(globalObject, buffer))
</ins><span class="cx">         return result;
</span><span class="cx">     buffer-&gt;ref();
</span><span class="cx">     JSC::JSArrayBuffer* wrapper = JSC::JSArrayBuffer::create(exec-&gt;vm(), globalObject-&gt;arrayBufferStructure(), buffer);
</span><del>-    cacheWrapper(currentWorld(exec), buffer, wrapper);
</del><ins>+    cacheWrapper(globalObject-&gt;world(), buffer, wrapper);
</ins><span class="cx">     return wrapper;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMWindowCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -594,7 +594,7 @@
</span><span class="cx"> JSValue JSDOMWindow::setTimeout(ExecState* exec)
</span><span class="cx"> {
</span><span class="cx">     ContentSecurityPolicy* contentSecurityPolicy = impl().document() ? impl().document()-&gt;contentSecurityPolicy() : 0;
</span><del>-    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, currentWorld(exec), contentSecurityPolicy);
</del><ins>+    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, globalObject()-&gt;world(), contentSecurityPolicy);
</ins><span class="cx">     if (exec-&gt;hadException())
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><span class="lines">@@ -613,7 +613,7 @@
</span><span class="cx"> JSValue JSDOMWindow::setInterval(ExecState* exec)
</span><span class="cx"> {
</span><span class="cx">     ContentSecurityPolicy* contentSecurityPolicy = impl().document() ? impl().document()-&gt;contentSecurityPolicy() : 0;
</span><del>-    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, currentWorld(exec), contentSecurityPolicy);
</del><ins>+    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, globalObject()-&gt;world(), contentSecurityPolicy);
</ins><span class="cx">     if (exec-&gt;hadException())
</span><span class="cx">         return jsUndefined();
</span><span class="cx">     int delay = exec-&gt;argument(1).toInt32(exec);
</span><span class="lines">@@ -638,7 +638,7 @@
</span><span class="cx">     if (!listener.isObject())
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    impl().addEventListener(exec-&gt;argument(0).toString(exec)-&gt;value(exec), JSEventListener::create(asObject(listener), this, false, currentWorld(exec)), exec-&gt;argument(2).toBoolean(exec));
</del><ins>+    impl().addEventListener(exec-&gt;argument(0).toString(exec)-&gt;value(exec), JSEventListener::create(asObject(listener), this, false, globalObject()-&gt;world()), exec-&gt;argument(2).toBoolean(exec));
</ins><span class="cx">     return jsUndefined();
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -652,7 +652,7 @@
</span><span class="cx">     if (!listener.isObject())
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    impl().removeEventListener(exec-&gt;argument(0).toString(exec)-&gt;value(exec), JSEventListener::create(asObject(listener), this, false, currentWorld(exec)).get(), exec-&gt;argument(2).toBoolean(exec));
</del><ins>+    impl().removeEventListener(exec-&gt;argument(0).toString(exec)-&gt;value(exec), JSEventListener::create(asObject(listener), this, false, globalObject()-&gt;world()).get(), exec-&gt;argument(2).toBoolean(exec));
</ins><span class="cx">     return jsUndefined();
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDocumentCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -53,11 +53,11 @@
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><span class="cx">     Location* location = frame-&gt;document()-&gt;domWindow()-&gt;location();
</span><del>-    if (JSObject* wrapper = getCachedWrapper(currentWorld(exec), location))
</del><ins>+    if (JSObject* wrapper = getCachedWrapper(globalObject()-&gt;world(), location))
</ins><span class="cx">         return wrapper;
</span><span class="cx"> 
</span><span class="cx">     JSLocation* jsLocation = JSLocation::create(getDOMStructure&lt;JSLocation&gt;(exec-&gt;vm(), globalObject()), globalObject(), location);
</span><del>-    cacheWrapper(currentWorld(exec), location, jsLocation);
</del><ins>+    cacheWrapper(globalObject()-&gt;world(), location, jsLocation);
</ins><span class="cx">     return jsLocation;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -80,14 +80,14 @@
</span><span class="cx">     if (!document)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), document);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), document);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span><span class="cx">     if (DOMWindow* domWindow = document-&gt;domWindow()) {
</span><span class="cx">         globalObject = toJSDOMWindow(toJS(exec, domWindow));
</span><span class="cx">         // Creating a wrapper for domWindow might have created a wrapper for document as well.
</span><del>-        wrapper = getCachedWrapper(currentWorld(exec), document);
</del><ins>+        wrapper = getCachedWrapper(globalObject-&gt;world(), document);
</ins><span class="cx">         if (wrapper)
</span><span class="cx">             return wrapper;
</span><span class="cx">     }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSElementCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSElementCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSElementCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSElementCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx">     if (!element)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    ASSERT(!getCachedWrapper(currentWorld(exec), element));
</del><ins>+    ASSERT(!getCachedWrapper(globalObject-&gt;world(), element));
</ins><span class="cx"> 
</span><span class="cx">     JSDOMWrapper* wrapper;        
</span><span class="cx">     if (element-&gt;isHTMLElement())
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSEventCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSEventCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSEventCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSEventCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -59,7 +59,7 @@
</span><span class="cx">     if (!event)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), event);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), event);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -57,7 +57,7 @@
</span><span class="cx">     if (!collection)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), collection);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), collection);
</ins><span class="cx"> 
</span><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLTemplateElementCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx"> 
</span><span class="cx">     DocumentFragment* content = impl().content();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), content);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject()-&gt;world(), content);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSImageDataCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -39,7 +39,7 @@
</span><span class="cx">     if (!imageData)
</span><span class="cx">         return jsNull();
</span><span class="cx">     
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), imageData);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), imageData);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx">     
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -196,7 +196,7 @@
</span><span class="cx"> static ALWAYS_INLINE JSValue createWrapperInline(ExecState* exec, JSDOMGlobalObject* globalObject, Node* node)
</span><span class="cx"> {
</span><span class="cx">     ASSERT(node);
</span><del>-    ASSERT(!getCachedWrapper(currentWorld(exec), node));
</del><ins>+    ASSERT(!getCachedWrapper(globalObject-&gt;world(), node));
</ins><span class="cx">     
</span><span class="cx">     JSDOMWrapper* wrapper;    
</span><span class="cx">     switch (node-&gt;nodeType()) {
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeCustomh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.h (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeCustom.h        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.h        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -40,7 +40,7 @@
</span><span class="cx">     if (!node)
</span><span class="cx">         return JSC::jsNull();
</span><span class="cx"> 
</span><del>-    JSNode* wrapper = JSC::jsCast&lt;JSNode*&gt;(getCachedWrapper(currentWorld(exec), node));
</del><ins>+    JSNode* wrapper = JSC::jsCast&lt;JSNode*&gt;(getCachedWrapper(globalObject-&gt;world(), node));
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSSVGPathSegCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -64,7 +64,7 @@
</span><span class="cx">     if (!object)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    if (JSObject* wrapper = getCachedWrapper(currentWorld(exec), object))
</del><ins>+    if (JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), object))
</ins><span class="cx">         return wrapper;
</span><span class="cx"> 
</span><span class="cx">     switch (object-&gt;pathSegType()) {
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSStyleSheetCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -50,7 +50,7 @@
</span><span class="cx">     if (!styleSheet)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), styleSheet);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), styleSheet);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -63,7 +63,7 @@
</span><span class="cx">     if (!cue)
</span><span class="cx">         return jsNull();
</span><span class="cx"> 
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), cue);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), cue);
</ins><span class="cx"> 
</span><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTrackCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -57,7 +57,7 @@
</span><span class="cx">     if (!track)
</span><span class="cx">         return jsNull();
</span><span class="cx">     
</span><del>-    JSObject* wrapper = getCachedWrapper(currentWorld(exec), track);
</del><ins>+    JSObject* wrapper = getCachedWrapper(globalObject-&gt;world(), track);
</ins><span class="cx">     if (wrapper)
</span><span class="cx">         return wrapper;
</span><span class="cx">     
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSWorkerGlobalScopeCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeCustom.cpp (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeCustom.cpp        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeCustom.cpp        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -95,7 +95,7 @@
</span><span class="cx"> 
</span><span class="cx"> JSValue JSWorkerGlobalScope::setTimeout(ExecState* exec)
</span><span class="cx"> {
</span><del>-    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, currentWorld(exec), impl().contentSecurityPolicy());
</del><ins>+    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, globalObject()-&gt;world(), impl().contentSecurityPolicy());
</ins><span class="cx">     if (exec-&gt;hadException())
</span><span class="cx">         return jsUndefined();
</span><span class="cx">     if (!action)
</span><span class="lines">@@ -106,7 +106,7 @@
</span><span class="cx"> 
</span><span class="cx"> JSValue JSWorkerGlobalScope::setInterval(ExecState* exec)
</span><span class="cx"> {
</span><del>-    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, currentWorld(exec), impl().contentSecurityPolicy());
</del><ins>+    OwnPtr&lt;ScheduledAction&gt; action = ScheduledAction::create(exec, globalObject()-&gt;world(), impl().contentSecurityPolicy());
</ins><span class="cx">     if (exec-&gt;hadException())
</span><span class="cx">         return jsUndefined();
</span><span class="cx">     if (!action)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (165913 => 165914)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2014-03-19 20:41:46 UTC (rev 165913)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2014-03-19 20:42:55 UTC (rev 165914)
</span><span class="lines">@@ -3032,10 +3032,10 @@
</span><span class="cx"> END
</span><span class="cx"> 
</span><span class="cx">         if ($svgPropertyType) {
</span><del>-            push(@implContent, &quot;    if (JSValue result = getExistingWrapper&lt;$className, $implType&gt;(exec, impl))\n&quot;);
</del><ins>+            push(@implContent, &quot;    if (JSValue result = getExistingWrapper&lt;$className, $implType&gt;(globalObject, impl))\n&quot;);
</ins><span class="cx">             push(@implContent, &quot;        return result;\n&quot;);
</span><span class="cx">         } else {
</span><del>-            push(@implContent, &quot;    if (JSValue result = getExistingWrapper&lt;$className&gt;(exec, impl))\n&quot;);
</del><ins>+            push(@implContent, &quot;    if (JSValue result = getExistingWrapper&lt;$className&gt;(globalObject, impl))\n&quot;);
</ins><span class="cx">             push(@implContent, &quot;        return result;\n&quot;);
</span><span class="cx">         }
</span><span class="cx">         push(@implContent, &lt;&lt;END) if $vtableNameGnu;
</span></span></pre>
</div>
</div>

</body>
</html>