mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 03:45:46 +00:00
Bug 1582554 - Add a preference for offset-path:ray(). r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D53110 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
b72f11ecca
commit
7a959a5da5
@ -8,6 +8,7 @@ prefs =
|
|||||||
gfx.omta.background-color=true
|
gfx.omta.background-color=true
|
||||||
layout.css.individual-transform.enabled=true
|
layout.css.individual-transform.enabled=true
|
||||||
layout.css.motion-path.enabled=true
|
layout.css.motion-path.enabled=true
|
||||||
|
layout.css.motion-path-ray.enabled=true
|
||||||
layout.css.overflow-logical.enabled=true
|
layout.css.overflow-logical.enabled=true
|
||||||
layout.css.step-position-jump.enabled=true
|
layout.css.step-position-jump.enabled=true
|
||||||
layout.css.text-underline-offset.enabled=true
|
layout.css.text-underline-offset.enabled=true
|
||||||
|
@ -4935,9 +4935,16 @@
|
|||||||
# Is support for motion-path enabled?
|
# Is support for motion-path enabled?
|
||||||
- name: layout.css.motion-path.enabled
|
- name: layout.css.motion-path.enabled
|
||||||
type: bool
|
type: bool
|
||||||
value: @IS_NOT_RELEASE_OR_BETA@
|
value: @IS_NIGHTLY_BUILD@
|
||||||
mirror: always
|
mirror: always
|
||||||
|
|
||||||
|
# Is support for motion-path ray() enabled?
|
||||||
|
- name: layout.css.motion-path-ray.enabled
|
||||||
|
type: RelaxedAtomicBool
|
||||||
|
value: @IS_NIGHTLY_BUILD@
|
||||||
|
mirror: always
|
||||||
|
rust: true
|
||||||
|
|
||||||
# Expose the media query -moz-touch-enabled to web content.
|
# Expose the media query -moz-touch-enabled to web content.
|
||||||
- name: layout.css.moz-touch-enabled.enabled
|
- name: layout.css.moz-touch-enabled.enabled
|
||||||
type: RelaxedAtomicBool
|
type: RelaxedAtomicBool
|
||||||
|
@ -16,11 +16,24 @@ use style_traits::{ParseError, StyleParseErrorKind};
|
|||||||
/// The specified value of `offset-path`.
|
/// The specified value of `offset-path`.
|
||||||
pub type OffsetPath = GenericOffsetPath<Angle>;
|
pub type OffsetPath = GenericOffsetPath<Angle>;
|
||||||
|
|
||||||
|
#[cfg(feature = "gecko")]
|
||||||
|
fn is_ray_enabled() -> bool {
|
||||||
|
static_prefs::pref!("layout.css.motion-path-ray.enabled")
|
||||||
|
}
|
||||||
|
#[cfg(feature = "servo")]
|
||||||
|
fn is_ray_enabled() -> bool {
|
||||||
|
false
|
||||||
|
}
|
||||||
|
|
||||||
impl Parse for RayFunction<Angle> {
|
impl Parse for RayFunction<Angle> {
|
||||||
fn parse<'i, 't>(
|
fn parse<'i, 't>(
|
||||||
context: &ParserContext,
|
context: &ParserContext,
|
||||||
input: &mut Parser<'i, 't>,
|
input: &mut Parser<'i, 't>,
|
||||||
) -> Result<Self, ParseError<'i>> {
|
) -> Result<Self, ParseError<'i>> {
|
||||||
|
if !is_ray_enabled() {
|
||||||
|
return Err(input.new_custom_error(StyleParseErrorKind::UnspecifiedError));
|
||||||
|
}
|
||||||
|
|
||||||
let mut angle = None;
|
let mut angle = None;
|
||||||
let mut size = None;
|
let mut size = None;
|
||||||
let mut contain = false;
|
let mut contain = false;
|
||||||
|
@ -1 +1 @@
|
|||||||
prefs: [layout.css.motion-path.enabled:true, layout.css.individual-transform.enabled:true, dom.animations-api.core.enabled:true]
|
prefs: [layout.css.motion-path.enabled:true, layout.css.individual-transform.enabled:true, dom.animations-api.core.enabled:true, layout.css.motion-path-ray.enabled:true]
|
||||||
|
Loading…
Reference in New Issue
Block a user