mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Remove global_root_from_reflector
This commit is contained in:
parent
1fed45e393
commit
26455b8a67
4 changed files with 5 additions and 11 deletions
|
@ -5,7 +5,7 @@
|
|||
//! Base classes to work with IDL callbacks.
|
||||
|
||||
use dom::bindings::error::{Error, Fallible, report_pending_exception};
|
||||
use dom::bindings::global::global_root_from_object;
|
||||
use dom::bindings::global::global_scope_from_object;
|
||||
use dom::bindings::reflector::Reflectable;
|
||||
use js::jsapi::{Heap, MutableHandleObject, RootedObject};
|
||||
use js::jsapi::{IsCallable, JSContext, JSObject, JS_WrapObject};
|
||||
|
@ -165,8 +165,8 @@ impl<'a> CallSetup<'a> {
|
|||
callback: &T,
|
||||
handling: ExceptionHandling)
|
||||
-> CallSetup<'a> {
|
||||
let global = unsafe { global_root_from_object(callback.callback()) };
|
||||
let cx = global.r().get_cx();
|
||||
let global = unsafe { global_scope_from_object(callback.callback()) };
|
||||
let cx = global.get_cx();
|
||||
|
||||
exception_compartment.ptr = unsafe {
|
||||
GetGlobalForObjectCrossCompartment(callback.callback())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue