Commit Graph

219 Commits

Author SHA1 Message Date
Boris Chiou
53644c1a40 Bug 1343753 - Part 4: Introduce AnimationValue::IsInterpolableWith. r=birtles,manishearth
We have different interpolation implementations on Gecko and Servo, so
wrap the "Can be Interpolated" in AnimationValue. This patch also introduces
the FFI, Servo_Animationvalues_IsInterpolable.

MozReview-Commit-ID: 92Yf1u84A3c
2017-04-12 16:26:59 +08:00
Boris Chiou
e62a6d13a7 Bug 1343753 - Part 3: Use AnimationValue in ElementPropertyTransition and CSSTransition. r=birtles
We also need to update the interpolation code based on ServoAnimationValue in
ElementPropertyTransition::UpdateStartValueFromReplacedTransition().
Therefore, ElementPropertyTransition can be used by both Gecko and Servo.

MozReview-Commit-ID: BrIpvRR3te8
2017-03-09 12:33:15 +08:00
Boris Chiou
5313bd87f1 Bug 1352067 - Part 2: Avoid passing any nullptr into Servo_AnimationValue_DeepEqual. r=hiro
The FFI type conversion in AnimationValue::as_arc will check if the
parameter is nullptr or not. If it is, we will get a debug assertion, so
we shouldn't pass a nullptr into it.

MozReview-Commit-ID: KWko2ipJwbo
2017-03-31 11:04:08 +08:00
Boris Chiou
781bb4be38 Bug 1352067 - Part 1: Make sure AnimationValue::{mGecko|mServo} are mutually exclusive. r=birtles,emilio
We will obsolete StyleAnimationValue in the future, and can treat
AnimationValue as a wrapper of RawServoAnimationValue to hide the FFIs
at that moment. For now, we still need both types, so it's better to make sure
they are mutually exclusive in AnimationValue. Therefore, let's add some
assertions.

Besides, I think those FFIs might do many things and it seems those methods
are not critical, so let's move them into the cpp file, so we can remove
some dependencies to avoid re-compiling so many files if someone needs
revise ServoBindings.h.

MozReview-Commit-ID: FJ1uTvEQ7NT
2017-03-31 17:46:37 +08:00
cku
1819876e04 Bug 1336905 - Part 1. Remove StyleShapeSource's template argument. r=heycam,TYLin
MozReview-Commit-ID: FHTwGyXHsce
2017-02-21 23:26:17 +08:00
Boris Chiou
d50c720532 Bug 1338087 - Part 2: Drop the computation of StyleAnimationValue on stylo. r=hiro
MozReview-Commit-ID: 4oAzC6m2vie
2017-02-10 15:51:00 +08:00
Daniel Holbert
d74b889d67 Bug 1339546 part 2: Make layout/style/*.cpp include corresponding .h file as the first header. r=xidorn
MozReview-Commit-ID: 2rZ9z0BgRvN
2017-02-14 11:23:11 -08:00
Carsten "Tomcat" Book
1bff0b1adf Backed out changeset fb3c04effbd1 (bug 1336905) for bustage in stylo builds 2017-02-14 11:07:17 +01:00
cku
b2b713cfd2 Bug 1336905 - Part 1. Remove StyleShapeSource's template argument. r=heycam,TYLin
MozReview-Commit-ID: FHTwGyXHsce
2017-02-06 15:50:22 +08:00
Boris Chiou
2c2e0bce5b Bug 1335942 - Part 6: Implement GetScaleValue for RawServoAnimationValue. r=hiro,manishearth
MozReview-Commit-ID: GnaS44gWmm2
2017-02-06 17:54:49 +08:00
Boris Chiou
d1fd8dc56d Bug 1335942 - Part 5: Add AnimationValue::GetScaleValue(). r=hiro
Move the common part of GetScaleValue into nsStyleTransformMatrix, and add a
new method, GetScaleValue, on AnimationValue, which can get the scale value from
StyleAnimationValue or RawServoAnimationValue.

MozReview-Commit-ID: 4spi1LkZrWP
2017-02-06 16:32:21 +08:00
Boris Chiou
f4d287d335 Bug 1335942 - Part 1: Introduce mozilla::AnimationValue. r=hiro,manishearth
Currently, we have StyleAnimationValue for Gecko and
RawServoAnimationValue for Servo, and use this struct to wrap them to
avoid the duplicated code.

MozReview-Commit-ID: ATDBSCOX2C5
2017-02-08 11:00:36 +08:00
Xidorn Quan
310f168604 Bug 1316236 - Treat perspective(0) as perspective(infinity). r=dholbert
MozReview-Commit-ID: H9xlpjxrzht
2017-01-20 12:45:33 +11:00
Hiroyuki Ikezoe
fb207a990a Bug 1330513- Check that mCSSValueList is null in case of filter and shadow in StyleAnimationValue::Add(). r=boris
The StyleAnimationValue for filter and shadow has no mCSSValueList in case of
initial style.

MozReview-Commit-ID: JigQQBbx77x
2017-01-12 19:42:14 +09:00
Ting-Yu Lin
9eb2a46c79 Bug 1320014 Part 11 - Convert NS_FULL_TO_HALF_CORNER to a constexpr function. r=mats
Because the new function checks types, we need to change the fullCorner type
in nsComputedDOMStyle::GetEllipseRadii() and
StyleAnimationValue::ExtractComputedValue() from uint8_t to |Corner| to fix
build error.

MozReview-Commit-ID: 5NuFE3yA2QD
2017-01-05 14:59:17 +08:00
Ting-Yu Lin
9feaa919bb Bug 1320014 Part 6 - Remove #define NS_CORNER_[TOP_LEFT/TOP_RIGHT/BOTTOM_RIGHT/BOTTOM_LEFT] r=mats
MozReview-Commit-ID: ERAwdxKZPf7
2017-01-04 18:15:30 +08:00
Wes Kocher
725e635b68 Merge inbound to central, a=merge
MozReview-Commit-ID: 1ij6nLf8f8s
2017-01-05 17:30:35 -08:00
Hiroyuki Ikezoe
dab6e73b6c Bug 1328535 - Remove range-checking assertion for aDilutionRatio, in color animation code. r=dholbert
Some cubic-bezier functions, e.g. cubic-bezier(0,-0.5,0,0), produce values out
of range of [0, 1].

MozReview-Commit-ID: 9ZTsTRTcUaI
2017-01-05 09:05:57 +09:00
Boris Zbarsky
db8c7b6474 Bug 1298588 part 10, gecko piece. Pass through useful default styles to apply_declarations(). r=bholley 2017-01-04 14:52:27 -05:00
Xidorn Quan
1f17806a81 Bug 1326125 - Rename enum version of SetIntValue to SetEnumValue. r=heycam
MozReview-Commit-ID: EbXK827IRFP
2016-12-29 10:22:49 +11:00
Xidorn Quan
1743a93199 Bug 1063162 part 1 - Add auto value support to StyleComplexColor. r=birtles
MozReview-Commit-ID: E6EFICyY3dh
2016-12-22 11:03:37 +11:00
Hiroyuki Ikezoe
dec485f2b1 Bug 1311620 - Part 11: Implement shadow list addition. r=boris
MozReview-Commit-ID: DRShA4qUS8Q
2016-12-24 20:05:34 +09:00
Hiroyuki Ikezoe
903a60b23a Bug 1311620 - Part 10: Implement filter list addition. r=boris
MozReview-Commit-ID: 8bQWBVveP9L
2016-12-24 20:04:56 +09:00
Hiroyuki Ikezoe
99c214dda1 Bug 1311620 - Part 9: Implement transform list addtion. r=boris.
MozReview-Commit-ID: 76b5eJ9FtWo
2016-12-24 20:04:52 +09:00
Hiroyuki Ikezoe
5be9417528 Bug 1311620 - Part 8: Implement color addition. r=boris
Actually this is the same as color accumulation.  Now we can pass test cases
that interpolation with overflowed values.

MozReview-Commit-ID: L4RqBhG5n3l
2016-12-24 20:03:48 +09:00
Hiroyuki Ikezoe
e84cd6194f Bug 1311620 - Part 4: Implement keyframe composite(add). r=birtles
This patch also fixes expected computed offset values in frame at 0.5 offset for
add composite.

MozReview-Commit-ID: 8PNp237NoV4
2016-12-24 19:54:27 +09:00
Sebastian Hengst
33c361b3ac Backed out changeset 5bc2005e01a6 (bug 1063162) for failing own test caret-color-01.html at least on OSX and Windows 8 x64. r=backout 2016-12-22 17:44:43 +01:00
Xidorn Quan
f09c2f7e50 Bug 1063162 part 1 - Add auto value support to StyleComplexColor. r=birtles
MozReview-Commit-ID: E6EFICyY3dh
2016-12-22 11:03:37 +11:00
Cameron McCormack
a191cdb1b5 Bug 1328546 - stylo: Support ServoStyleSheets in nsIStyleSheetService::PreloadSheet and nsIDOMWindowUtils::AddSheet. r=bholley
MozReview-Commit-ID: 2KOMrnCf1Ag
2017-01-05 15:32:22 +08:00
Xidorn Quan
cc24e912e2 Bug 1311870 - Change property id of moz-prefixed properties to match their name. r=heycam
MozReview-Commit-ID: DkrMkzMq5qM
2016-12-21 18:16:50 +11:00
Hiroyuki Ikezoe
b8deef2535 Bug 1323114 - Handle interpolation between 'none' and 'accumulate matrix' as different transform list. r=boris
MozReview-Commit-ID: HoyOKsMxmDH
2016-12-21 06:12:33 +09:00
cku
237643d3a6 NO BUG - Remove empty lines.
MozReview-Commit-ID: K7GMiRAJYPJ
2016-12-16 15:46:26 +08:00
Daniel Holbert
8ba94824b0 Bug 1321022 pt 6: Use UniquePtr instead of nsAutoPtr (& nsCSSValue setters) in font-variations-setting StyleAnimationValue code. r=jfkthame
MozReview-Commit-ID: CSj2wcZlTJs
2016-12-03 12:18:43 +00:00
Jonathan Kew
da7246294e Bug 1321022 pt 5 - Add support for animating the font-variations-setting property. r=dholbert 2016-12-03 12:18:41 +00:00
Carsten "Tomcat" Book
2ee161bf4e merge mozilla-inbound to mozilla-central a=merge 2016-11-24 16:41:59 +01:00
Cameron McCormack
3bd168f1a5 Bug 1319336 - Add some assertions and early returns to animation code to make stylo tests progress further. r=birtles
MozReview-Commit-ID: 14rghu0zYG1
2016-11-24 12:45:51 +08:00
Ting-Yu Lin
7e10b6ab51 Bug 1317588 Part 3 - Remove #define NS_SIDE_TOP/RIGHT/BOTTOM/LEFT. r=mats
This patch was written with the help of the following script. Also, manually
add mozilla qualifier to the enum values in nsStyleCoord.h, gfxRect.h, and
Types.h to make it build.

function rename() {
find .\
     -type f\
     ! -path "./obj*"\
     ! -path "./.git"\
     ! -path "./.hg"\
     \( -name "*.cpp" -or\
        -name "*.h" \)\
        -exec sed -i -e "s/$1/$2/g" "{}" \;
}

rename "NS_SIDE_TOP" "eSideTop"
rename "NS_SIDE_RIGHT" "eSideRight"
rename "NS_SIDE_BOTTOM" "eSideBottom"
rename "NS_SIDE_LEFT" "eSideLeft"

MozReview-Commit-ID: 9T0ORsqM6nP
2016-11-18 18:12:25 +08:00
Ting-Yu Lin
03d0c3c4c4 Bug 1317588 Part 2 - Remove mozilla::css::Side typedef. r=mats
This patch is written with the help of the following script.

function rename() {
find .\
     -type f\
     ! -path "./obj*"\
     ! -path "./.git"\
     ! -path "./.hg"\
     \( -name "*.cpp" -or\
        -name "*.h" \)\
        -exec sed -i -e "s/$1/$2/g" "{}" \;
}

rename "css::Side" "Side"

MozReview-Commit-ID: DPV6vivpPUp
2016-11-18 16:28:38 +08:00
Boris Chiou
85ab71627f Bug 1286151 - Part 7: Make ComputeShapeDistance return the status. r=hiro
We should follow the rules used by other types - return false if computing
the distance is failed. So make ComputeShapeDistance and return the status
and let the last argument be the output distance.

MozReview-Commit-ID: CFoQhgyqILB
2016-11-17 11:52:41 +08:00
Boris Chiou
fd88128e44 Bug 1286151 - Part 4: Factor out ComputeSingleShadowSquareDistance. r=dholbert
Both eUnit_Shadow and the drop-shadow of eUnit_Filter needs to compute the
distance of two shadows, so we can factor out the implementation.

MozReview-Commit-ID: IGdxQWMXdE1
2016-11-15 11:58:16 +08:00
Boris Chiou
1741d4d758 Bug 1286151 - Part 3: Implement filter distance for the rest. r=hiro
MozReview-Commit-ID: EXBzvJ7PIwQ
2016-11-10 17:25:10 +08:00
Boris Chiou
a224f0ffed Bug 1286151 - Part 2: Implement filter distance for drop-shadow. r=hiro
MozReview-Commit-ID: 5Ad0GiWGkJg
2016-11-10 17:46:35 +08:00
Boris Chiou
4cc47548fb Bug 1286151 - Part 1: Implement filter distance for blur. r=hiro
MozReview-Commit-ID: 44EP55V8ldg
2016-11-10 15:15:52 +08:00
Hiroyuki Ikezoe
3e0e0a2190 Bug 1304886 - Part 9: Accumulate mismatched transform list properly. r=boris
MozReview-Commit-ID: LTz4TkCsMbQ
2016-11-16 20:32:33 +09:00
Hiroyuki Ikezoe
9659b093bb Bug 1304886 - Part 8: Add Accumulate operator. r=boris,derf
MozReview-Commit-ID: Bzcn3IRSx6L
2016-11-16 20:32:33 +09:00
Hiroyuki Ikezoe
06e0ac11c7 Bug 1304886 - Part 3: Move InterpolateTransformMatrix into nsStyleTransformMatrix. r=boris
MozReview-Commit-ID: 7GV6B7AwNcg
2016-11-16 20:32:32 +09:00
Hiroyuki Ikezoe
f78feb6ce9 Bug 1304886 - Part 2: Factor out TransformFunctionListsMatch. r=boris
MozReview-Commit-ID: BhRkF6ClJjv
2016-11-16 20:32:32 +09:00
Hiroyuki Ikezoe
723ccec4d8 Bug 1304886 - Part 1: Make StyleAnimationValue::Accumulate() infallible. r=birtles
MozReview-Commit-ID: 9ve3k6a3eAg
2016-11-16 20:32:26 +09:00
Manish Goregaokar
486ae2d4e5 Bug 1314200 - stylo: support transform; r=heycam
MozReview-Commit-ID: 50YhZtjF3vH
2016-10-31 16:30:43 -07:00
Boris Chiou
687077584f Bug 1286150 - Part 5: Implement shape distance for inset. r=hiro
MozReview-Commit-ID: 4C2uZp9qM3D
2016-10-27 15:34:06 +08:00