mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Auto merge of #10292 - jdm:cssom, r=jdm
Initial steps for CSSOM Squashed and rebased #10133. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10292) <!-- Reviewable:end -->
This commit is contained in:
commit
f335586ff5
15 changed files with 159 additions and 77 deletions
|
@ -69,6 +69,7 @@ use dom::nodelist::NodeList;
|
|||
use dom::processinginstruction::ProcessingInstruction;
|
||||
use dom::range::Range;
|
||||
use dom::servohtmlparser::{ParserRoot, ParserRef, MutNullableParserField};
|
||||
use dom::stylesheetlist::StyleSheetList;
|
||||
use dom::text::Text;
|
||||
use dom::touch::Touch;
|
||||
use dom::touchevent::TouchEvent;
|
||||
|
@ -1724,6 +1725,11 @@ impl Element {
|
|||
}
|
||||
|
||||
impl DocumentMethods for Document {
|
||||
// https://drafts.csswg.org/cssom/#dom-document-stylesheets
|
||||
fn StyleSheets(&self) -> Root<StyleSheetList> {
|
||||
StyleSheetList::new(&self.window, JS::from_ref(&self))
|
||||
}
|
||||
|
||||
// https://dom.spec.whatwg.org/#dom-document-implementation
|
||||
fn Implementation(&self) -> Root<DOMImplementation> {
|
||||
self.implementation.or_init(|| DOMImplementation::new(self))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue