mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
style: Fix a warning in layout-2020
This commit is contained in:
parent
bb8c3ee8ba
commit
a7d740331d
1 changed files with 9 additions and 8 deletions
|
@ -34,18 +34,19 @@ fn moz_box_display_values_enabled(context: &ParserContext) -> bool {
|
|||
static_prefs::pref!("layout.css.xul-box-display-values.content.enabled")
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "servo-layout-2020"))]
|
||||
fn flexbox_enabled() -> bool {
|
||||
#[cfg(feature = "servo-layout-2020")]
|
||||
{
|
||||
return servo_config::prefs::pref_map()
|
||||
.get("layout.flexbox.enabled")
|
||||
.as_bool()
|
||||
.unwrap_or(false);
|
||||
}
|
||||
|
||||
true
|
||||
}
|
||||
|
||||
#[cfg(feature = "servo-layout-2020")]
|
||||
fn flexbox_enabled() -> bool {
|
||||
servo_config::prefs::pref_map()
|
||||
.get("layout.flexbox.enabled")
|
||||
.as_bool()
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
/// Defines an element’s display type, which consists of
|
||||
/// the two basic qualities of how an element generates boxes
|
||||
/// <https://drafts.csswg.org/css-display/#propdef-display>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue