style: Add CssPropFlags::SerializedByServo and use it on some simple properties.

The idea is to turn the simple properties into a blacklist instead really soon,
and fix the offending ones soon after, so that only shorthands and properties
with layout dependence (and maybe the scrollbar properties, because the poke at
LookAndFeel) are not serialized by Servo.

Bug: 1467536
Reviewed-by: xidorn
MozReview-Commit-ID: JTLNnmXzny8
This commit is contained in:
Emilio Cobos Álvarez 2018-06-07 21:07:28 +02:00
parent 011cad2534
commit d65b29da27
No known key found for this signature in database
GPG key ID: 056B727BB9C1027C

View file

@ -226,6 +226,10 @@ class Longhand(object):
# See compute_damage for the various values this can take
self.servo_restyle_damage = servo_restyle_damage
@staticmethod
def type():
return "longhand"
def experimental(self, product):
if product == "gecko":
return bool(self.gecko_pref)
@ -361,6 +365,10 @@ class Shorthand(object):
animatable = property(get_animatable)
transitionable = property(get_transitionable)
@staticmethod
def type():
return "shorthand"
def experimental(self, product):
if product == "gecko":
return bool(self.gecko_pref)
@ -392,6 +400,10 @@ class Alias(object):
self.allowed_in_page_rule = original.allowed_in_page_rule
self.allowed_in_keyframe_block = original.allowed_in_keyframe_block
@staticmethod
def type():
return "alias"
def experimental(self, product):
if product == "gecko":
return bool(self.gecko_pref)