Bug 1419695: Hide multiple -moz-window-* properties from content. r?xidorn
MozReview-Commit-ID: Jsqt3kqjPiq
--- a/layout/style/ServoCSSPropList.mako.py
+++ b/layout/style/ServoCSSPropList.mako.py
@@ -53,19 +53,16 @@ def is_internal(prop):
# A property which is not controlled by pref and not enabled in
# content by default is an internal property.
if not prop.gecko_pref and not prop.enabled_in_content():
return True
# There are some special cases we may want to remove eventually.
OTHER_INTERNALS = [
"-moz-context-properties",
"-moz-control-character-visibility",
- "-moz-window-opacity",
- "-moz-window-transform",
- "-moz-window-transform-origin",
]
return prop.name in OTHER_INTERNALS
def method(prop):
if prop.name == "float":
return "CssFloat"
if prop.name.startswith("-x-"):
return prop.camel_case[1:]
--- a/layout/style/test/test_non_content_accessible_properties.html
+++ b/layout/style/test/test_non_content_accessible_properties.html
@@ -4,21 +4,19 @@
<style id="sheet"></style>
<div></div>
<script>
const NON_CONTENT_ACCESSIBLE_PROPERTIES = [
"-x-span",
"-x-lang",
"-x-text-zoom",
"-moz-window-shadow",
- // FIXME(bug 1419695): These should be hidden, but Gecko would refuse to
- // transition them. We need to fix that.
- // "-moz-window-opacity",
- // "-moz-window-transform",
- // "-moz-window-transform-origin",
+ "-moz-window-opacity",
+ "-moz-window-transform",
+ "-moz-window-transform-origin",
"-moz-top-layer",
"-moz-script-size-multiplier",
"-moz-script-level",
"-moz-math-display",
"-moz-math-variant",
"-moz-script-min-size",
"-moz-font-smoothing-background-color",
"-moz-min-font-size-ratio",
--- a/servo/components/style/properties/longhand/ui.mako.rs
+++ b/servo/components/style/properties/longhand/ui.mako.rs
@@ -36,45 +36,50 @@
${helpers.single_keyword("-moz-window-shadow", "none default menu tooltip sheet", products="gecko",
gecko_ffi_name="mWindowShadow",
gecko_constant_prefix="NS_STYLE_WINDOW_SHADOW",
animation_value_type="discrete",
enabled_in="chrome",
spec="None (Nonstandard internal property)")}
-// TODO(bug 1419695) This should be hidden from content.
-${helpers.predefined_type("-moz-window-opacity", "Opacity", "1.0", products="gecko",
- gecko_ffi_name="mWindowOpacity",
- animation_value_type="ComputedValue",
- spec="None (Nonstandard internal property)")}
+${helpers.predefined_type(
+ "-moz-window-opacity",
+ "Opacity",
+ "1.0",
+ products="gecko",
+ gecko_ffi_name="mWindowOpacity",
+ animation_value_type="ComputedValue",
+ spec="None (Nonstandard internal property)",
+ enabled_in="chrome",
+)}
-// TODO(bug 1419695) This should be hidden from content.
${helpers.predefined_type(
"-moz-window-transform",
"Transform",
"generics::transform::Transform::none()",
products="gecko",
gecko_ffi_name="mSpecifiedWindowTransform",
flags="GETCS_NEEDS_LAYOUT_FLUSH",
animation_value_type="ComputedValue",
- spec="None (Nonstandard internal property)"
+ spec="None (Nonstandard internal property)",
+ enabled_in="chrome",
)}
-// TODO(bug 1419695) This should be hidden from content.
${helpers.predefined_type(
"-moz-window-transform-origin",
"TransformOrigin",
"computed::TransformOrigin::initial_value()",
animation_value_type="ComputedValue",
gecko_ffi_name="mWindowTransformOrigin",
products="gecko",
boxed=True,
flags="GETCS_NEEDS_LAYOUT_FLUSH",
- spec="None (Nonstandard internal property)"
+ spec="None (Nonstandard internal property)",
+ enabled_in="chrome",
)}
// TODO(emilio): Probably also should be hidden from content.
${helpers.predefined_type("-moz-force-broken-image-icon",
"MozForceBrokenImageIcon",
"computed::MozForceBrokenImageIcon::false_value()",
animation_value_type="discrete",
products="gecko",