mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
auto merge of #1811 : Ms2ger/servo/Wrap_, r=jdm
This commit is contained in:
commit
da6a571f9e
28 changed files with 65 additions and 72 deletions
|
@ -87,10 +87,10 @@ impl Document {
|
|||
pub fn reflect_document<D: Reflectable+DocumentBase>
|
||||
(document: ~D,
|
||||
window: &JS<Window>,
|
||||
wrap_fn: extern "Rust" fn(*JSContext, *JSObject, ~D) -> *JSObject)
|
||||
wrap_fn: extern "Rust" fn(*JSContext, &JS<Window>, ~D) -> *JSObject)
|
||||
-> JS<D> {
|
||||
assert!(document.reflector().get_jsobject().is_null());
|
||||
let raw_doc = reflect_dom_object(document, window.get(), wrap_fn);
|
||||
let raw_doc = reflect_dom_object(document, window, wrap_fn);
|
||||
assert!(raw_doc.reflector().get_jsobject().is_not_null());
|
||||
|
||||
let document = DocumentCast::from(&raw_doc);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue