Remove GlobalRoot and GlobalRef

This commit is contained in:
Anthony Ramine 2016-10-05 10:29:38 +02:00
parent c66cf46bee
commit b6bbd41e11
13 changed files with 63 additions and 173 deletions

View file

@ -8,7 +8,6 @@
use dom::bindings::callback::ExceptionHandling;
use dom::bindings::cell::DOMRefCell;
use dom::bindings::codegen::Bindings::PromiseBinding::PromiseJobCallback;
use dom::bindings::global::global_scope_from_object;
use dom::bindings::js::{Root, RootCollection, RootCollectionPtr, trace_roots};
use dom::bindings::refcounted::{LiveDOMReferences, trace_refcounted_objects};
use dom::bindings::trace::trace_traceables;
@ -178,7 +177,7 @@ unsafe extern "C" fn enqueue_job(_cx: *mut JSContext,
_allocation_site: HandleObject,
_data: *mut c_void) -> bool {
let result = panic::catch_unwind(AssertUnwindSafe(|| {
let global = global_scope_from_object(job.get());
let global = GlobalScope::from_object(job.get());
let pipeline = global.pipeline_id();
global.enqueue_promise_job(EnqueuedPromiseCallback {
callback: PromiseJobCallback::new(job.get()),