It's a bit unfortunate the use separate implementations of SpecifiedUrl for Servo
and Gecko, but they're different enough at this point that I don't think it really
makes sense to try to share everything. Splitting them out has some nice
simplifications as well.
I recognize that there's still some potential correctness issues for Servo using
the resolved URI in various places where the original URI may be the right thing,
but I've got too much on my plate to look into that for now.
MozReview-Commit-ID: BeDu93TQ4Ow
nsStyleContext::CalcDifference had an optimization where, when we knew
that the old and new style context have the same rule node, we knew that
the only change hints that would need to be handled are those in the
"not handled for descendants" category, generated due to explicit
'inherit' values on reset properties. This was because any changes due
to differences in inherited properties should only have generated
"handled for descendants" change hints (and thus would already have been
handled on an ancestor).
Before bug 931668, this let us avoid calling CalcDifference on structs
that only would have generated hints that we knew we already would have
handled. However, after bug 931668, we compare all structs anyway so
that we can set the aEqualStructs outparam, so we don't gain anything
from this optimization. We can still return these change hints we know
will not need to be handled, and rely on ElementRestyler::CaptureChange
to filter them out.
MozReview-Commit-ID: Ld1s2Js0i6r
This runnable is to delete object only, so using system group should be
fine.
MozReview-Commit-ID: 8uMxMO3yERG
--HG--
extra : rebase_source : 75ae4953d4c91fa0ab9a0c598a1989fa122f8f5a
Before this patch, we store each computed values in a hashtable,
nsRefPtrHashtable<nsUint32HashKey, RawServoAnimationValue>, for all
KeyframeEffectReadOnly on an element, and convert the ServoAnimationValues of
the hashtable into an nsTArray<ServoAnimationValue*> and then convert
the ServoAnimationValues of the nsTArray into PropertyDeclarationBlock
in rust. This way was really inefficient.
In this patch, we store the computed values into AnimationValueMap and
convert all AnimationValue in the map into PropertyDeclarationBlock
after EffectCompositor::GetAnimationRule.
MozReview-Commit-ID: EJ2Kl65fVeF
--HG--
extra : rebase_source : e30a9d440dc9855e21b94501b07a3501d31bc345
The only one caller of GetServoAnimationRule is Gecko_GetAnimationRule.
There is no risk that pres context is destroyed in Gecko_GetAnimationRule.
MozReview-Commit-ID: 52pxbCiCNoJ
--HG--
extra : rebase_source : 8000e267d1d5706c709f807e11396dda3579c4dc
cssPseudoElementBeforeProperty and cssPseudoElementAfterProperty are for
CSSPseudoElement.
MozReview-Commit-ID: 3WETv4QeC5
--HG--
extra : rebase_source : b7e902786ca9ebe7c92a573604e15d868c6067a7
We create the SequentialTask only if:
* We have no old computed values and we have animation name style in the new
computed values.
* Any animation properties is changed.
* display property is changed from 'none' and we have animation name style.
* display property is changed to 'none'.
In a subsequent patch we skip the SequentialTask if we have no running
animations and the display propery is changed to 'none'.
MozReview-Commit-ID: JRSZznufOS2
--HG--
extra : rebase_source : 566026c21c6357f77df55e3bd588835f5fd6c3d4
Later we update CSS animations if this function returns false.
MozReview-Commit-ID: 27FsYQ40gSv
--HG--
extra : rebase_source : a043282de6c8a50ed53a92de98ecf93eb042f188
This introduces a basic framework for servo's style system to be able
to query the style of presentation attributes which it can then insert
into the cascade. It uses that framework to implement the size and
color attributes on <font>.
There are a number of improvements that can be done on top of this:
- Implement all other properties
- Abstractify the ruledata parameter of the mappers using templates or virtual dispatch so that it can be a Servo decl block instead
- Implement aforementiond abstraction over Servo decl blocks (this obsoletes the code in the first item above, so it might just be better to skip that and directly do this)
- Replace uses of nsHTMLStyleSheet with an abstract base class containing common elements between Servo and Gecko
I'd prefer for these to be done in separate steps.
MozReview-Commit-ID: GO60qfeZOfl
--HG--
extra : rebase_source : 516d369a8627e413983361aaf85ccb7132b0a06c
This is a function which is called in Servo_StyleSet_FillKeyframesForName to
append a Gecko's Keyframe into nsTArray<Keyframe>.
Without this function we need to end up exposing ComputedTimingFunction class
and Maybe<> as FFI.
MozReview-Commit-ID: 2EpltR4rMVh