mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Avoid selector-matching when only the style attribute is changed.
This commit is contained in:
parent
da89099e26
commit
8859aa004f
5 changed files with 235 additions and 41 deletions
|
@ -50,6 +50,14 @@ bitflags! {
|
|||
}
|
||||
}
|
||||
|
||||
impl RestyleHint {
|
||||
/// The subset hints that affect the styling of a single element during the
|
||||
/// traversal.
|
||||
pub fn for_single_element() -> Self {
|
||||
RESTYLE_SELF | RESTYLE_STYLE_ATTRIBUTE
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "gecko")]
|
||||
impl From<nsRestyleHint> for RestyleHint {
|
||||
fn from(raw: nsRestyleHint) -> Self {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue