style: Move moz-control-character-visibility out of mako, and remove support for gecko_pref_controlled_initial_value

No behavior change, just cleanup. Actually seem this technically _adds_ some code even
though it's a cleanup, but that's mostly because of the wrapping of the
derive list.  The resulting code is simpler (more in-line with our usual
things, so I think it's an improvement).

Differential Revision: https://phabricator.services.mozilla.com/D111551
This commit is contained in:
Oriol Brufau 2023-05-16 23:17:16 +02:00
parent fac547276f
commit 743f213c25
5 changed files with 48 additions and 32 deletions

View file

@ -1028,6 +1028,39 @@ pub enum TextJustify {
InterCharacter,
}
/// Values for the `-moz-control-character-visibility` CSS property.
#[repr(u8)]
#[derive(
Clone,
Copy,
Debug,
Eq,
MallocSizeOf,
Parse,
PartialEq,
SpecifiedValueInfo,
ToComputedValue,
ToCss,
ToResolvedValue,
ToShmem,
)]
#[allow(missing_docs)]
pub enum MozControlCharacterVisibility {
Hidden,
Visible,
}
impl Default for MozControlCharacterVisibility {
fn default() -> Self {
if static_prefs::pref!("layout.css.control-characters.visible") {
Self::Visible
} else {
Self::Hidden
}
}
}
/// Values for the `line-break` property.
#[repr(u8)]
#[derive(