mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Rename nsIDocument to mozilla::dom::Document.
Summary: Really sorry for the size of the patch. It's mostly automatic s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to add the right namespacing and such. Overall it's not a very interesting patch I think. nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and nsIDocumentInlines.h into DocumentInlines.h. I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it. While fixing up some of the bits I also removed some unneeded OwnerDoc() null checks and such, but I didn't do anything riskier than that. Bug: 1517241 Reviewed-by: smaug
This commit is contained in:
parent
274845fc14
commit
a454f6233d
4 changed files with 12 additions and 13 deletions
|
@ -7,8 +7,7 @@
|
|||
use crate::context::QuirksMode;
|
||||
use crate::dom::TElement;
|
||||
use crate::gecko_bindings::bindings::{self, RawServoStyleSet};
|
||||
use crate::gecko_bindings::structs::StyleSheet as DomStyleSheet;
|
||||
use crate::gecko_bindings::structs::{nsIDocument, StyleSheetInfo};
|
||||
use crate::gecko_bindings::structs::{StyleSheet as DomStyleSheet, StyleSheetInfo};
|
||||
use crate::gecko_bindings::structs::{RawGeckoPresContextBorrowed, ServoStyleSetSizes};
|
||||
use crate::gecko_bindings::sugar::ownership::{HasArcFFI, HasBoxFFI, HasFFI, HasSimpleFFI};
|
||||
use crate::invalidation::media_queries::{MediaListKey, ToMediaListKey};
|
||||
|
@ -152,7 +151,7 @@ impl PerDocumentStyleData {
|
|||
//
|
||||
// Should we just force XBL Stylists to be NoQuirks?
|
||||
let quirks_mode =
|
||||
unsafe { (*device.pres_context().mDocument.raw::<nsIDocument>()).mCompatMode };
|
||||
unsafe { (*device.pres_context().mDocument.mRawPtr).mCompatMode };
|
||||
|
||||
PerDocumentStyleData(AtomicRefCell::new(PerDocumentStyleDataImpl {
|
||||
stylist: Stylist::new(device, quirks_mode.into()),
|
||||
|
@ -198,7 +197,7 @@ impl PerDocumentStyleDataImpl {
|
|||
.device()
|
||||
.pres_context()
|
||||
.mDocument
|
||||
.raw::<nsIDocument>();
|
||||
.mRawPtr;
|
||||
unsafe { bindings::Gecko_VisitedStylesEnabled(doc) }
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue