mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Use upcast() in XMLDocument methods.
This commit is contained in:
parent
0633ca4144
commit
3f95e4c8e1
1 changed files with 3 additions and 3 deletions
|
@ -76,16 +76,16 @@ impl XMLDocument {
|
|||
impl XMLDocumentMethods for XMLDocument {
|
||||
// https://html.spec.whatwg.org/multipage/#dom-document-location
|
||||
fn GetLocation(&self) -> Option<Root<Location>> {
|
||||
self.document.GetLocation()
|
||||
self.upcast::<Document>().GetLocation()
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-tree-accessors:supported-property-names
|
||||
fn SupportedPropertyNames(&self) -> Vec<DOMString> {
|
||||
self.document.SupportedPropertyNames()
|
||||
self.upcast::<Document>().SupportedPropertyNames()
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-tree-accessors:dom-document-nameditem-filter
|
||||
fn NamedGetter(&self, _cx: *mut JSContext, name: DOMString, found: &mut bool) -> *mut JSObject {
|
||||
self.document.NamedGetter(_cx, name, found)
|
||||
self.upcast::<Document>().NamedGetter(_cx, name, found)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue