mirror of
https://github.com/servo/servo.git
synced 2025-08-09 07:25:35 +01:00
style: Add a pref and enable Shadow Parts in Nightly and for chrome stylesheets.
I want to enable in Nightly to evaluate (in the medium term) shipping it without the part forwarding, once the cascade order and importance issues are fixed, and that we pass all the tests that don't involve forwarding. That is, I want to monitor whether having ::part() causes compat issues or not. Differential Revision: https://phabricator.services.mozilla.com/D32649
This commit is contained in:
parent
e272bfed70
commit
8b0d2b1e38
1 changed files with 9 additions and 2 deletions
|
@ -5,7 +5,7 @@
|
||||||
//! Gecko-specific bits for selector-parsing.
|
//! Gecko-specific bits for selector-parsing.
|
||||||
|
|
||||||
use crate::element_state::{DocumentState, ElementState};
|
use crate::element_state::{DocumentState, ElementState};
|
||||||
use crate::gecko_bindings::structs::RawServoSelectorList;
|
use crate::gecko_bindings::structs::{self, RawServoSelectorList};
|
||||||
use crate::gecko_bindings::sugar::ownership::{HasBoxFFI, HasFFI, HasSimpleFFI};
|
use crate::gecko_bindings::sugar::ownership::{HasBoxFFI, HasFFI, HasSimpleFFI};
|
||||||
use crate::invalidation::element::document_state::InvalidationMatchingData;
|
use crate::invalidation::element::document_state::InvalidationMatchingData;
|
||||||
use crate::selector_parser::{Direction, SelectorParser};
|
use crate::selector_parser::{Direction, SelectorParser};
|
||||||
|
@ -349,7 +349,14 @@ impl<'a, 'i> ::selectors::Parser<'i> for SelectorParser<'a> {
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
fn parse_host(&self) -> bool {
|
fn parse_host(&self) -> bool {
|
||||||
self.parse_slotted()
|
true
|
||||||
|
}
|
||||||
|
|
||||||
|
#[inline]
|
||||||
|
fn parse_part(&self) -> bool {
|
||||||
|
self.chrome_rules_enabled() || unsafe {
|
||||||
|
structs::StaticPrefs_sVarCache_layout_css_shadow_parts_enabled
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn parse_non_ts_pseudo_class(
|
fn parse_non_ts_pseudo_class(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue