Commit graph

16155 commits

Author SHA1 Message Date
bors-servo
8824a68063 Auto merge of #16625 - birtles:smil-support, r=hiro,heycam
SMIL support for Gecko

PR for [Gecko bug 1355348](https://bugzilla.mozilla.org/show_bug.cgi?id=1355348)

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes do not require tests because they are tested on the Gecko side

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16625)
<!-- Reviewable:end -->
2017-04-27 00:48:21 -05:00
Boris Chiou
e27c86fc49 Fix inaccurate input progress in the final animation frame. 2017-04-27 12:24:52 +08:00
Boris Chiou
f1feddf52c Add frames into style system and update animation with frames functions. 2017-04-27 12:24:50 +08:00
Brian Birtles
af9c7fc257 Add restyle hint for SMIL animations 2017-04-27 13:20:37 +09:00
Brian Birtles
ba118dfe69 Rename remove_animation_and_transition_rules to just remove_animation_rules
Now this method covers SMIL override rules, CSS animation / script
animation rules, and CSS transition rules so we should just use
"animation" in the generic sense.
2017-04-27 13:20:36 +09:00
Brian Birtles
2c3c9d673d Get SMIL override styles from Gecko 2017-04-27 13:20:23 +09:00
Brian Birtles
97ce9ed5b0 Add SMIL override cascade level 2017-04-27 12:35:12 +09:00
Aaron Cunningham
f6d09a39f8 Move impl's into macro for macro-generated keyword types
Three keyword types are created through a macro but have some of their
impl's handled elsewhere. Since all impl's are the same, this commit
moves them into the macro to have them auto generated, for more concise
code.
2017-04-26 12:38:21 -07:00
bors-servo
18c72ac28d Auto merge of #16620 - CJKu:bug-1341703, r=heycam,manishearth
Bug 1341703 - Support border-image with url()

<!-- Please describe your changes on the following line: -->
Gecko 1341703 should be land immediately after this PR been merged.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16620)
<!-- Reviewable:end -->
2017-04-26 12:39:57 -05:00
bors-servo
74656f4ff0 Auto merge of #16619 - servo:rustup, r=jdm
Update rustc to 1.18.0-nightly (b0a4074c5 2017-04-26)

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16619)
<!-- Reviewable:end -->
2017-04-26 11:30:36 -05:00
cku
2f91276280 Stylo: Remove the second parameter(with_url) of nsStyleImage::set. 2017-04-27 00:07:38 +08:00
cku
53279596db Stylo: Make sure that the URL stylo parse for border-image-source is propagated to Gecko computed style. 2017-04-27 00:07:33 +08:00
Anthony Ramine
c234bf92d0 Update rustc to 1.18.0-nightly (b0a4074c5 2017-04-26) 2017-04-26 17:34:34 +02:00
Anthony Ramine
f872fdac9a Make Stylist::quirks_mode hold a QuirksMode 2017-04-26 17:30:28 +02:00
bors-servo
8f1356de60 Auto merge of #16614 - BorisChiou:stylo/transition/transition_property, r=emilio
stylo: Bug 1357357 - Make the parser of transition-property match the spec.

These are interdependent patches of Bug 1357357. We add one more arm, TransitionProperty::Unsupported, which stores the string of non-animatable, custom, or unrecognized property, so we can parse these kinds of properties and serialize them correctly. This is necessary because we need to start transitions even though some transition-properties are non-animatable, custom, or unrecognized.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix [Bug 1357357](https://bugzilla.mozilla.org/show_bug.cgi?id=1357357).
- [X] There are tests for these changes.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16614)
<!-- Reviewable:end -->
2017-04-26 09:33:08 -05:00
bors-servo
4e70e10ed1 Auto merge of #16618 - emilio:dirty-doc, r=nox
script: Ensure we don't suppress reflows when stylesheets are dirty.

I suspect this will prevent some intermittentness in #16617

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16618)
<!-- Reviewable:end -->
2017-04-26 08:59:33 -05:00
Boris Chiou
02fc1789e8 Bug 1357357 - Make the parser of transition-property match the spec.
1. We add a new arm to TransitionProperty, TransitionProperty::Unsupported,
   which contains an Atom, so it's better to remove the Copy trait from
   TransitionProperty.
2. TransitionProperty::Unsupported(Atom) represents any non-animatable, custom,
   or unrecognized property, and we use Atom to store the ident string for
   serialization.
2017-04-26 21:35:05 +08:00
Emilio Cobos Álvarez
69fd9a3e9b
script: Ensure we don't suppress reflows when stylesheets are dirty. 2017-04-26 15:32:56 +02:00
bors-servo
c1b347794c Auto merge of #16612 - glennw:update-wr-groove-ridge-2, r=jdm
Update WR (groove/ridge borders, mix-blend-mode opts)

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16612)
<!-- Reviewable:end -->
2017-04-26 07:56:32 -05:00
Hiroyuki Ikezoe
1a37e69ce9 Fix overflow in ::nth-child() 2017-04-26 19:20:13 +09:00
bors-servo
e5762cb695 Auto merge of #16613 - birtles:clear-animation-dirty-bit, r=hiikezoe
Clear animation-only dirty descendants bit on display:none descendants

PR for [Gecko bug 1359658](https://bugzilla.mozilla.org/show_bug.cgi?id=1359658)

When an element has a display:none ancestor we don't traverse it during
restyle. However, at the end of restyling we expect the tree to be free
of dirty bits. We currently take special care to clear the regular
(non-animation) dirty bit on nodes in display:none subtrees in order to
preserve this invariant. This patch applies the same handling to the
animation-only dirty descendants bit.

---
- [X] `./mach build -d` just keeps crashing because mozjs calls sed.exe in a way that breaks it
- [X] `./mach test-tidy` does not report any errors
- [X] There are tests for these changes on the Gecko side

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16613)
<!-- Reviewable:end -->
2017-04-26 01:47:00 -05:00
Brian Birtles
0d0c2701ff Clear animation-only dirty descendants bit on display:none descendants
When an element has a display:none ancestor we don't traverse it during
restyle. However, at the end of restyling we expect the tree to be free
of dirty bits. We currently take special care to clear the regular
(non-animation) dirty bit on nodes in display:none subtrees in order to
preserve this invariant. This patch applies the same handling to the
animation-only dirty descendants bit.
2017-04-26 14:14:30 +09:00
Glenn Watson
c879584a19 Update WR (new groove/ridge border path, mix-blend-mode optimizations)
A few other minor additions too.
2017-04-26 14:34:07 +10:00
Simon Sapin
029150c770 Exclude 'none' from <counter-style-name> after all.
https://github.com/w3c/csswg-drafts/issues/1295
2017-04-26 06:18:58 +02:00
Simon Sapin
be38c9a5a7 Consider foo and "foo" equal as keyframes/animation names. 2017-04-26 13:04:28 +09:00
Simon Sapin
0ff64bdc59 Allow 'decimal' and 'none' in <counter-style-name>
… other than in `@counter-style`.
2017-04-26 13:04:27 +09:00
Simon Sapin
1146921866 Keep custom-ident and string separate in animation/keyframes name. 2017-04-26 13:04:22 +09:00
Simon Sapin
82c04113d0 Make predefined counter style names ASCII-lowercase. 2017-04-26 13:03:21 +09:00
Simon Sapin
e7a2a98d8a Make the style::counter_style module a directory 2017-04-26 13:02:41 +09:00
Simon Sapin
ade56bbe8d Add missing 'additive-symbols' validity checks 2017-04-26 13:02:40 +09:00
Simon Sapin
331acfaf9b Check rule-level @counter-style validity 2017-04-26 13:02:38 +09:00
Simon Sapin
6dc317f80b Add speak-as descriptor for @counter-style 2017-04-26 13:02:37 +09:00
Simon Sapin
62d261add4 Add 'additive-symbols' descriptor for @counter-style 2017-04-26 13:02:36 +09:00
Simon Sapin
f93a9a4b10 Don’t make up initial values not in spec for @counter-style descriptors 2017-04-26 13:02:34 +09:00
Simon Sapin
617e8e9768 CSSOM requires @counter-style to keep track of which descriptors were specified 2017-04-26 13:02:33 +09:00
Simon Sapin
fe15663423 Add the 'symbols' descriptor for @counter-style 2017-04-26 13:02:31 +09:00
Simon Sapin
0ba5cae707 Add 'fallback' descriptor to @counter-style 2017-04-26 13:02:30 +09:00
Simon Sapin
e27de3842d Add 'pad' descritor of @counter-style 2017-04-26 13:02:29 +09:00
Simon Sapin
6f79684468 Add 'range' descriptor to @counter-style 2017-04-26 13:02:27 +09:00
Simon Sapin
29bcb5b636 Add 'prefix' and 'suffix' descriptors for @counter-style 2017-04-26 13:02:26 +09:00
Simon Sapin
d1558a2025 Add 'negative' descriptor of @counter-style 2017-04-26 13:02:25 +09:00
Simon Sapin
4477a2da40 Add the 'system' descriptor of @counter-style 2017-04-26 13:02:23 +09:00
Simon Sapin
797f40b0a3 Add initial style system support for @counter-style rules 2017-04-26 13:02:22 +09:00
Simon Sapin
5a8e3308c1 Remove some intermediate conversions in style/properties/gecko.mako.rs 2017-04-26 13:02:20 +09:00
Simon Sapin
627c823d0a Use CustomIdent in counter-increment 2017-04-26 13:02:17 +09:00
Simon Sapin
d9c2d1a9fb Use CustomIdent for animation-name and @keyframes 2017-04-26 13:02:16 +09:00
Simon Sapin
4993a80074 Introduce a style::values::CustomIdent type 2017-04-26 13:02:14 +09:00
bors-servo
5daf92dd5a Auto merge of #16611 - Manishearth:stylo-controlchar, r=heycam
stylo: Add support for -moz-control-character-visibility

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16611)
<!-- Reviewable:end -->
2017-04-25 21:31:14 -05:00
Manish Goregaokar
247da8f7f8 Add support for -moz-control-character-visibility
MozReview-Commit-ID: 2fdaQrDi6Xt
2017-04-25 18:32:26 -07:00
bors-servo
09f0ff7481 Auto merge of #16608 - emilio:refactor-fixup, r=jryans
style: Move all the fixup code into a StyleAdjuster struct.

This will allow reusing it from text styles, which we need for some corner
cases, like text-align: -moz-center and similar stuff.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16608)
<!-- Reviewable:end -->
2017-04-25 20:31:00 -05:00