Servo/StyleUpdateOnDOMChange: Difference between revisions

Line 52: Line 52:


== Options for Servo ==
== Options for Servo ==
One thing we want to decide up front is how we want to handle '+' and '~', and possibly other things the CSS working group will decide to do in terms of allowing flagging of arbitrary parts of a selector as the subject.  Neither the WebKit nor Gecko approaches make me entirely happy.
One thing that Servo will have that neither WebKit nor Gecko does is the ability to consider both the pre-change and post-change states of the DOM, if we're willing to do such processing as part of the "discard the old read pointers" process.  This can allow us to completely or partially defer processing of whether restyles are needed from when changes are actually made to the discarding process.  Unfortunately, what that will require is running said deferred processing on the DOM thread, since that's the only place we can safely access both the old and new DOM states.  We may want to restrict this to only particular things where the win from having access to both the old and new value is particularly meaningful (e.g. class attribute changes)?
308

edits