Emilio Cobos Álvarez
bc970596d6
layout: Make animations work... more or less.
...
There's some maths I've done wrong, but it DOES animate some things, though
they're only triggered past the first restyle, and we probably have some
duplications where the animations arrive to layout.
Anyway, got to go.
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
c16c5acade
style: Rewrite the animation representation to allow having state in layout
...
I have to make the appropriate changes in layout, but I'm running out of battery
in the bus.
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
5b27e46d04
style: Atomize animation names.
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
0077eb147c
style: Actually animate something!
...
So this actually allows some more animations to be triggered. The bad part of
this is that they're actually triggered always when the style is recalculated,
so we're going to have at least some more state into the node, and the
constellation, which would have to keep track of the animations states.
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
f389cf61c4
style: Make animation functions as generic as possible.
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
6a362ae8e8
style: Refactor all the animated properties to use the style system properly
2016-06-28 15:09:53 +00:00
Emilio Cobos Álvarez
60192bb830
style: Refactor to pass animations cleanly, land animation-name parsing as experimental
2016-06-28 15:09:53 +00:00
Ms2ger
79e0d18a1d
Add some documentation to the style crate.
2016-06-27 17:33:14 +02:00
Cullen Rhodes
40acd24e8f
Report use statements that use {} with only one entry
2016-05-27 10:18:44 +01:00
Cameron McCormack
550d780e17
Move width and height from Box to Position.
...
This helps with style struct alignment between Servo and Gecko.
2016-05-04 11:06:42 +10:00
Per Lundberg
c7758a8ad8
Removed the T prefix for the style traits
...
More work as described in #10185 .
The reason I upgraded lazy_static to 0.1.16 is because it fixes an issue with the Box name (std::boxed::Box was used in an unqualified name, which can cause name clashes when there is another type that exists with the same name).
2016-04-12 23:02:02 +03:00
Mauricio Collares
c3d6bfc3df
Move some CSS properties from Animation to Box and delete Animation
2016-04-05 00:28:19 -03:00
Mauricio Collares
d8222dd63d
Move CSS line-height property from InheritedBox to InheritedText
2016-04-05 00:28:18 -03:00
Mauricio Collares
aae8919da4
Move some CSS properties from Box to Position
2016-04-05 00:21:49 -03:00
Mauricio Collares
281e385ab2
Rename PositionOffsets to Position
2016-04-05 00:21:48 -03:00
Mauricio Collares
8c8090b5cd
Move CSS text-shadow property from Effects to InheritedText
2016-04-05 00:21:46 -03:00
Per Lundberg
4cb4cc93e4
Renamed TComputedValues to ComputedValues
...
This is a followup to #10210 , and a continuation of #10185 .
2016-03-29 23:30:13 +03:00
Per Lundberg
c2ad084713
ComputedValues is now ServoComputedValues
...
This is the first part of #10185 . More to follow. I have built this locally with both servo and geckolib without errors; let's see if it succeeds on all platforms as well.
2016-03-27 10:55:43 +03:00
Bobby Holley
c2daea2c9c
Parameterize the rest of the style system on TNode.
2016-03-24 11:50:57 -07:00
Bobby Holley
5c749127cc
Introduce traits for style structs and computed values.
2016-03-24 11:49:46 -07:00
Anthony Ramine
09f865919d
Move util::bezier to style
2016-02-14 19:45:24 +01:00
Emilio Cobos Álvarez
61e04df266
style: Refactor the per_pseudo map from StyleData to avoid having an option value type.
...
This make the layout code way clearer.
2016-02-13 16:05:17 +01:00
Bobby Holley
513a75d86a
Hoist the rest of css/matching.rs into style/.
2016-01-04 09:41:31 -08:00
Bobby Holley
a05d7f1dfd
Hoist style-related context bits into style/.
...
We do a few things-here:
* Hoist non-layout-dependent fields in SharedLayoutData and LocalLayoutData into style/.
* Hoist parts of css/matching.rs into style/.
* Hoist parts of layout/animation.rs into style/animation.rs.
* Remove the duplicated-but-slightly-different definition of OpaqueNode.
2015-12-29 12:07:07 -08:00
Tetsuharu OHZEKI
e8c12c1c6d
Fix warnings: Use Vec.extend_from_slice instead of Vec.push_all
2015-12-10 16:49:29 -05:00
David Zbarsky
00980ea595
Implement calc expressions for more value types
2015-11-01 23:16:14 -08:00
Glenn Watson
339a3f869b
Split Au type into separate crate, with minimal dependencies.
2015-10-01 07:16:11 +10:00
Jaydeep
2a99915188
Check for Extra pointer dereferencing. Issue #7640 .
2015-09-26 19:33:29 -07:00
Ravi Shankar
889eec364b
sorted the extern crate, mod & use declarations
2015-09-24 02:12:45 +05:30
Michael Howell
554a4cf9f2
Add transitions for CSS calc()
.
...
Closes #7284
2015-09-19 19:39:55 -07:00
Brandon Fairchild
de3547e401
Fix reported test-tidy errors for unmerged import blocks
...
This merges import blocks that were reported by tidy as unmerged.
2015-09-19 12:50:14 -04:00
Jinwoo Song
d524601cf5
CSS 'transformation: skew()' should take <angle> type as parameters
...
Current implementation is taking <number> type as parameter so skew()
does not work properly. Let the skew() to get <angle> as specification
described.
Fixes #6237 .
2015-09-12 01:06:35 +02:00
Manish Goregaokar
97422ad252
Various fixes in style
2015-09-03 03:16:00 +05:30
Simon Sapin
40b4348824
Upgrade to rustc 1.4.0-dev (cb9323ec0 2015-09-01)
2015-09-02 09:22:17 +02:00
Johann Tuffe
ec07178b6f
sort all uses
2015-08-20 20:47:12 +08:00
Josh Matthews
8bb853f643
Fix existing syntactics nits.
2015-08-16 10:30:43 -04:00
João Oliveira
0038580abf
Replace uses of for foo in bar.iter()
and for foo in bar.iter_mut()
...
closes #7197
2015-08-15 02:27:39 +01:00
Patrick Walton
cac01edf80
style: Switch animation timestamps to be doubles instead of floats.
...
32-bit floats are not enough to hold timestamps since the epoch and
result in jank.
2015-08-01 17:46:39 -07:00
Patrick Walton
ad7bfa2289
style: Fix misdirected animation properties.
...
left redirected to top, and padding redirected to margin.
2015-08-01 10:23:41 -07:00
David Zbarsky
e484d6b5e3
Implement getComputedStyle
2015-07-29 20:17:50 -04:00
Glenn Watson
c27388cb81
Change transforms to use LengthOrPercentage.
...
This simplifies an upcoming PR to support serializing transform values for css style declarations.
Related to issue #6643 .
2015-07-28 09:42:05 +10:00
Glenn Watson
6dd082278d
Partial implementation of transform animations spec.
...
Also tidy up some of the ComputedMatrix code.
2015-06-10 07:07:28 +10:00
Simon Sapin
ef8edd4e87
Upgrade to rustc 551a74dddd84cf01440ee84148ebd18bc68bd7c8.
2015-05-05 10:07:34 -04:00
Joseph Seaton
d843526cb8
Animate many more CSS properties
2015-04-16 17:42:57 +01:00
Patrick Walton
66dd8c8a6c
layout: Implement CSS transitions per CSS-TRANSITIONS § 2.
...
Transition events are not yet supported, and the only animatable
properties are `top`, `right`, `bottom`, and `left`. However, all other
features of transitions are supported. There are no automated tests at
present because I'm not sure how best to test it, but three manual tests
are included.
2015-03-31 08:46:11 -07:00