Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Unified Diff: trunk/Source/bindings/templates/interface.cpp

Issue 218813002: Revert 170357 "Revert of Make DOMWrapperWorld::current() return ..." (Closed) Base URL: svn://svn.chromium.org/blink/
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « trunk/Source/bindings/templates/interface.h ('k') | trunk/Source/bindings/tests/idls/SVGTestInterface.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/Source/bindings/templates/interface.cpp
===================================================================
--- trunk/Source/bindings/templates/interface.cpp (revision 170423)
+++ trunk/Source/bindings/templates/interface.cpp (working copy)
@@ -662,7 +662,7 @@
thus passing it around would cause leakage.
2) Errors cannot be cloned (or serialized):
http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#safe-passing-of-structured-data #}
- if (DOMWrapperWorld::current(isolate)->isIsolatedWorld()) {
+ if (DOMWrapperWorld::current(isolate).isIsolatedWorld()) {
{% for attribute in any_type_attributes %}
if (!{{attribute.name}}.IsEmpty())
event->setSerialized{{attribute.name | blink_capitalize}}(SerializedScriptValue::createAndSwallowExceptions({{attribute.name}}, isolate));
@@ -975,7 +975,7 @@
{% filter conditional(method.conditional_string) %}
{% if method.is_do_not_check_security %}
{% if method.is_per_world_bindings %}
- if (DOMWrapperWorld::current(isolate)->isMainWorld()) {
+ if (DOMWrapperWorld::current(isolate).isMainWorld()) {
{{install_do_not_check_security_signature(method, 'ForMainWorld')}}
} else {
{{install_do_not_check_security_signature(method)}}
@@ -985,7 +985,7 @@
{% endif %}
{% else %}{# is_do_not_check_security #}
{% if method.is_per_world_bindings %}
- if (DOMWrapperWorld::current(isolate)->isMainWorld()) {
+ if (DOMWrapperWorld::current(isolate).isMainWorld()) {
{% filter runtime_enabled(method.runtime_enabled_function) %}
{{install_custom_signature(method, 'ForMainWorld')}}
{% endfilter %}
@@ -1203,7 +1203,7 @@
{% if interface_name == 'Window' %}
v8::Handle<v8::ObjectTemplate> V8Window::getShadowObjectTemplate(v8::Isolate* isolate)
{
- if (DOMWrapperWorld::current(isolate)->isMainWorld()) {
+ if (DOMWrapperWorld::current(isolate).isMainWorld()) {
DEFINE_STATIC_LOCAL(v8::Persistent<v8::ObjectTemplate>, V8WindowShadowObjectCacheForMainWorld, ());
if (V8WindowShadowObjectCacheForMainWorld.IsEmpty()) {
TRACE_EVENT_SCOPED_SAMPLING_STATE("Blink", "BuildDOMTemplate");
@@ -1244,8 +1244,8 @@
{% if is_document %}
if (wrapper.IsEmpty())
return wrapper;
- DOMWrapperWorld* world = DOMWrapperWorld::current(isolate);
- if (world->isMainWorld()) {
+ DOMWrapperWorld& world = DOMWrapperWorld::current(isolate);
+ if (world.isMainWorld()) {
if (LocalFrame* frame = impl->frame())
frame->script().windowShell(world)->updateDocumentWrapper(wrapper);
}
« no previous file with comments | « trunk/Source/bindings/templates/interface.h ('k') | trunk/Source/bindings/tests/idls/SVGTestInterface.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698