mirror of
https://github.com/servo/servo.git
synced 2025-08-08 06:55:31 +01:00
Fixes #4164 Make Constructor and new functions take GlobalRef by value
This commit is contained in:
parent
cf616b90a2
commit
85df7f0d6f
25 changed files with 61 additions and 61 deletions
|
@ -48,13 +48,13 @@ impl ErrorEvent {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn new_uninitialized(global: &GlobalRef) -> Temporary<ErrorEvent> {
|
||||
pub fn new_uninitialized(global: GlobalRef) -> Temporary<ErrorEvent> {
|
||||
reflect_dom_object(box ErrorEvent::new_inherited(EventTypeId::ErrorEvent),
|
||||
*global,
|
||||
global,
|
||||
ErrorEventBinding::Wrap)
|
||||
}
|
||||
|
||||
pub fn new(global: &GlobalRef,
|
||||
pub fn new(global: GlobalRef,
|
||||
type_: DOMString,
|
||||
bubbles: EventBubbles,
|
||||
cancelable: EventCancelable,
|
||||
|
@ -75,7 +75,7 @@ impl ErrorEvent {
|
|||
Temporary::from_rooted(ev.r())
|
||||
}
|
||||
|
||||
pub fn Constructor(global: &GlobalRef,
|
||||
pub fn Constructor(global: GlobalRef,
|
||||
type_: DOMString,
|
||||
init: &ErrorEventBinding::ErrorEventInit) -> Fallible<Temporary<ErrorEvent>>{
|
||||
let msg = match init.message.as_ref() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue