mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
style: Remove a bunch of now completely dead XUL layout code
And some related tests. A bunch of -moz-box* properties are web exposed, so I'll file a follow-up for hiding them. Differential Revision: https://phabricator.services.mozilla.com/D173819
This commit is contained in:
parent
46a569ef45
commit
0748fd9582
2 changed files with 0 additions and 35 deletions
|
@ -55,16 +55,6 @@ ${helpers.single_keyword(
|
|||
spec="None (internal)",
|
||||
)}
|
||||
|
||||
${helpers.single_keyword(
|
||||
"-moz-box-layout",
|
||||
"flex legacy",
|
||||
engines="gecko",
|
||||
gecko_enum_prefix="StyleMozBoxLayout",
|
||||
animation_value_type="none",
|
||||
enabled_in="chrome",
|
||||
spec="None (internal)",
|
||||
)}
|
||||
|
||||
${helpers.single_keyword(
|
||||
"text-orientation",
|
||||
"mixed upright sideways",
|
||||
|
|
|
@ -22,11 +22,6 @@ use std::fmt::{self, Debug, Formatter, Write};
|
|||
use style_traits::{CssWriter, KeywordsCollectFn, ParseError};
|
||||
use style_traits::{SpecifiedValueInfo, StyleParseErrorKind, ToCss};
|
||||
|
||||
#[cfg(feature = "gecko")]
|
||||
fn moz_display_values_enabled(context: &ParserContext) -> bool {
|
||||
context.in_ua_or_chrome_sheet()
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "servo"))]
|
||||
fn flexbox_enabled() -> bool {
|
||||
true
|
||||
|
@ -54,8 +49,6 @@ pub enum DisplayOutside {
|
|||
InternalTable,
|
||||
#[cfg(feature = "gecko")]
|
||||
InternalRuby,
|
||||
#[cfg(feature = "gecko")]
|
||||
XUL,
|
||||
}
|
||||
|
||||
#[allow(missing_docs)]
|
||||
|
@ -89,8 +82,6 @@ pub enum DisplayInside {
|
|||
RubyTextContainer,
|
||||
#[cfg(feature = "gecko")]
|
||||
WebkitBox,
|
||||
#[cfg(feature = "gecko")]
|
||||
MozBox,
|
||||
}
|
||||
|
||||
#[allow(missing_docs)]
|
||||
|
@ -185,12 +176,6 @@ impl Display {
|
|||
DisplayInside::RubyTextContainer,
|
||||
);
|
||||
|
||||
/// XUL boxes.
|
||||
#[cfg(feature = "gecko")]
|
||||
pub const MozBox: Self = Self::new(DisplayOutside::Block, DisplayInside::MozBox);
|
||||
#[cfg(feature = "gecko")]
|
||||
pub const MozInlineBox: Self = Self::new(DisplayOutside::Inline, DisplayInside::MozBox);
|
||||
|
||||
/// Make a raw display value from <display-outside> and <display-inside> values.
|
||||
#[inline]
|
||||
const fn new(outside: DisplayOutside, inside: DisplayInside) -> Self {
|
||||
|
@ -294,8 +279,6 @@ impl Display {
|
|||
DisplayInside::Flex => true,
|
||||
#[cfg(feature = "gecko")]
|
||||
DisplayInside::Grid => true,
|
||||
#[cfg(feature = "gecko")]
|
||||
DisplayInside::MozBox => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
|
@ -334,8 +317,6 @@ impl Display {
|
|||
Display::from3(DisplayOutside::Block, inside, self.is_list_item())
|
||||
},
|
||||
DisplayOutside::Block | DisplayOutside::None => *self,
|
||||
#[cfg(feature = "gecko")]
|
||||
DisplayOutside::XUL => *self,
|
||||
_ => Display::Block,
|
||||
}
|
||||
}
|
||||
|
@ -386,8 +367,6 @@ impl ToCss for Display {
|
|||
Display::InlineBlock => dest.write_str("inline-block"),
|
||||
#[cfg(feature = "gecko")]
|
||||
Display::WebkitInlineBox => dest.write_str("-webkit-inline-box"),
|
||||
#[cfg(feature = "gecko")]
|
||||
Display::MozInlineBox => dest.write_str("-moz-inline-box"),
|
||||
Display::TableCaption => dest.write_str("table-caption"),
|
||||
_ => match (outside, inside) {
|
||||
#[cfg(feature = "gecko")]
|
||||
|
@ -548,10 +527,6 @@ impl Parse for Display {
|
|||
"-webkit-box" => Display::WebkitBox,
|
||||
#[cfg(feature = "gecko")]
|
||||
"-webkit-inline-box" => Display::WebkitInlineBox,
|
||||
#[cfg(feature = "gecko")]
|
||||
"-moz-box" if moz_display_values_enabled(context) => Display::MozBox,
|
||||
#[cfg(feature = "gecko")]
|
||||
"-moz-inline-box" if moz_display_values_enabled(context) => Display::MozInlineBox,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue