Commit graph

15859 commits

Author SHA1 Message Date
Martin Robinson
ee73cb618a Remove unused StackingContextType
This hasn't been in use for quite some time.
2017-08-16 11:08:54 +02:00
Ting-Yu Lin
0e82ca1d3a style: Skip matching :nth-child if element is the root of anonymous subtree
This implement the logic in Gecko's nsNthIndexCache::GetNthIndex().

MozReview-Commit-ID: 8lzK9iIbfzo
2017-08-16 14:25:01 +08:00
bors-servo
dc654c9912 Auto merge of #18099 - KuoE0:make-empty-rule-can-be-inserted-into-rule-tree, r=emilio
Make emtpy rule can be inserted into rule tree

<!-- Please describe your changes on the following line: -->
We really want to ensure empty rule nodes appear in the rule tree for devtools, this condition ensures that if we find an empty rule node, we insert it at the normal level.

---
<!-- 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
- [X] These changes fix [Bug 1384802](https://bugzilla.mozilla.org/show_bug.cgi?id=1384802)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because of the test cases are in Gecko.

<!-- 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/18099)
<!-- Reviewable:end -->
2017-08-15 23:11:04 -05:00
J. Ryan Stinnett
711adba0ce Update Stylo bindings 2017-08-15 22:09:08 -05:00
KuoE0
a6ceafe3da Make emtpy rule can be inserted into rule tree 2017-08-16 11:08:49 +08:00
J. Ryan Stinnett
d4b364200a Fix up Gecko_CalcStyleDifference for Linux 32-bit ABI
Bindgen bitfield enums don't work as return values with the Linux 32-bit ABI at
the moment because they wrap the value in a struct.

This causes the Rust side to believe the callee expects space for the struct
return value, while C++ believes it's just an integer value.

MozReview-Commit-ID: FRBqlZuMiAR
2017-08-15 21:10:37 -05:00
bors-servo
eba896157e Auto merge of #18095 - emilio:unused, r=bholley
stylo: Remove some unused FFI functions.

Bug: 1390650
Reviewed-by: bholley
MozReview-Commit-ID: K9fXGRmgkr4

<!-- 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/18095)
<!-- Reviewable:end -->
2017-08-15 19:29:45 -05:00
bors-servo
1c4076a759 Auto merge of #18040 - atouchet:user-agent, r=jdm
Update Firefox version in user agent

<!-- Please describe your changes on the following line: -->
GitHub has started throwing warnings about using an outdated version of Firefox when loaded with Servo. I am assuming that this is due to Servo using Firefox 37.0 in its user agent which was set in 2015 and hasn't been updated since then. I don't know if updating this should cause any site compatibility issues or not.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./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/18040)
<!-- Reviewable:end -->
2017-08-15 18:21:51 -05:00
bors-servo
99b4b7e960 Auto merge of #18094 - bholley:ancestor_reconstruct, r=emilio
Avoid leaving stale ANCESTOR_WAS_RECONSTRUCTED bits in the tree

https://bugzilla.mozilla.org/show_bug.cgi?id=1390179

<!-- 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/18094)
<!-- Reviewable:end -->
2017-08-15 17:07:20 -05:00
Emilio Cobos Álvarez
6b6ab991fd
stylo: Remove some unused FFI functions.
Bug: 1390650
Reviewed-by: bholley
MozReview-Commit-ID: K9fXGRmgkr4
2017-08-15 23:57:59 +02:00
Bobby Holley
8a3761972d Bonus fix: Be more robust about clearing descendants bits under display:none subtrees.
MozReview-Commit-ID: 9KQVOpdEjwF
2017-08-15 14:25:50 -07:00
Bobby Holley
05a1b682bb Avoid leaving stale ANCESTOR_WAS_RECONSTRUCTED bits in the tree.
MozReview-Commit-ID: 76q5XxK2o2a
2017-08-15 14:25:50 -07:00
Imanol Fernandez
703962fe61 Improve WebGL architecture. 2017-08-15 22:14:32 +02:00
Simon Sapin
b5a4b8d6a0 Upgrade to rustc 1.21.0-nightly (13d94d5fa 2017-08-10) 2017-08-15 14:10:44 +02:00
bors-servo
41fb10c589 Auto merge of #18085 - dadaa:make-content-animatable, r=hiro
Make content animatable

<!-- Please describe your changes on the following line: -->

---
<!-- 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

<!-- Either: -->
- [X] There are tests for these changes. The test codes are patch part 3 and 4 in https://bugzilla.mozilla.org/show_bug.cgi?id=1382136

<!-- 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/18085)
<!-- Reviewable:end -->
2017-08-15 05:50:15 -05:00
bors-servo
526d573e07 Auto merge of #18084 - hiikezoe:currentcolor-for-box-shadow-animation, r=xidorn
Currentcolor for box shadow animation

<!-- Please describe your changes on the following line: -->
https://bugzilla.mozilla.org/show_bug.cgi?id=1388220
---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/18084)
<!-- Reviewable:end -->
2017-08-15 04:37:44 -05:00
bors-servo
87c872a7f7 Auto merge of #18081 - hiikezoe:interpolation-with-auto, r=birtles,boris,mantaroh
Fix interpolation between auto and other values

<!-- Please describe your changes on the following line: -->
https://bugzilla.mozilla.org/show_bug.cgi?id=1387939

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/18081)
<!-- Reviewable:end -->
2017-08-15 03:28:21 -05:00
bors-servo
74558990b2 Auto merge of #17425 - paulrouget:attach-pipeline-2, r=asajeffrey
cleanup embedder/compositor/constellation/script messages

Fix: #17226 #17200 #17201

This is work in progress. Some tests still fail.
I'd like to get early feedback as it's a pretty large PR.

There is nothing fundamentally new. Basically, I added TopLevelBrowsingContrextId to the relevant messages between the embedder, the compositor and the constellation, and enforced the PipelineId to be attached to each ScriptMsg (see #17201).

I unaliased all the ScriptMsg. It was getting difficult to understand the nature of the message as ScriptMsg was used aliased CompositorMsg sometimes (CompositorMsg is an actually type of message already). I renamed constellation_chan to script_to_constellation_chan, again, for clarification.

This cleanup code is necessary for #15934 and for tabs support.

/cc @asajeffrey can I ask you to look at this? No need for a formal review, I need feedback at this stage.

<!-- 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/17425)
<!-- Reviewable:end -->
2017-08-15 02:20:10 -05:00
Daisuke Akatsuka
87c932dff6 Make content animatable 2017-08-15 15:25:06 +09:00
Daisuke Akatsuka
c05baa2327 Implement clone_content method 2017-08-15 15:25:05 +09:00
Paul Rouget
d9e7bdd7f6 Event to make a browser visible 2017-08-15 08:22:13 +02:00
Paul Rouget
6876e42d66 rename Browser to Servo as we support multiple browsers 2017-08-15 08:22:11 +02:00
Paul Rouget
d241389129 make use of ScriptToConstellationChan 2017-08-15 08:22:09 +02:00
Hiroyuki Ikezoe
95994bd710 Convert gecko's currentcolor to servo one. 2017-08-15 15:19:47 +09:00
Hiroyuki Ikezoe
4665d6dd15 Reuse to_simple_shadow() for box-shadow as well. 2017-08-15 15:19:31 +09:00
Emilio Cobos Álvarez
3e2d87d8db
style: Simplify the ruby text adjustment.
StyleBuilder keeps a reference to the parent style, so no need to get it as an
argument.
2017-08-15 07:49:54 +02:00
bors-servo
e0b834033d Auto merge of #18079 - hiikezoe:moz-image-region, r=boris
Don't convert zero component value to 'auto' in clone__moz_image_region.

Currently Gecko treats 'auto' component value as zero for animation.

<!-- Please describe your changes on the following line: -->

https://bugzilla.mozilla.org/show_bug.cgi?id=1387951

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/18079)
<!-- Reviewable:end -->
2017-08-14 23:31:19 -05:00
Hiroyuki Ikezoe
08ebc524cf Round halfway values toward positive infinity for integer type of animation.
From the spec[1];

 `with values halfway between a pair of integers rounded towards positive infinity.`

[1] https://drafts.csswg.org/css-transitions/#animtype-integer
2017-08-15 13:05:15 +09:00
Hiroyuki Ikezoe
bff67d8272 Don't fallback to discrete animation within add_weighted() for Either<>.
For CSS Transitions we want this case to return Err() so we know that the two
values are not interpolable.

For CSS Animations/Web Animations we implement discrete animation as the
fallback behavior when Err() is returned.
2017-08-15 13:04:07 +09:00
Hiroyuki Ikezoe
fa3b62746d ComputedPositiveInteger is an integer greater than or equal to 1. 2017-08-15 13:03:54 +09:00
Hiroyuki Ikezoe
19d498f01e Make assertion for colum-count more accurate.
column-count should be greater than or equal to 1. Also it should be less than
or equal to nsStyleColumn_kMaxColumnCount since we limit it in
set_column_count().
2017-08-15 13:03:33 +09:00
Hiroyuki Ikezoe
f6b8fb177c Check interpolatable to tell whether transition is created or not. 2017-08-15 13:03:18 +09:00
Hiroyuki Ikezoe
6d49d8151c Don't convert zero component value to 'auto' in clone__moz_image_region.
Currently Gecko treats 'auto' component value as zero for animation.
2017-08-15 12:34:45 +09:00
bors-servo
0aba7442a6 Auto merge of #18078 - hiikezoe:vertical-align-animation, r=boris
Make vertical-align animatable between percentage and percentage or l…

…ength.

<!-- Please describe your changes on the following line: -->
https://bugzilla.mozilla.org/show_bug.cgi?id=1387949

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/18078)
<!-- Reviewable:end -->
2017-08-14 22:07:31 -05:00
bors-servo
4771e6ea1e Auto merge of #18076 - upsuper:fullscreen-pref, r=TYLin
Check pref when parsing :fullscreen pseudo-class

This is the Servo side change of [bug 1374902](https://bugzilla.mozilla.org/show_bug.cgi?id=1374902).

<!-- 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/18076)
<!-- Reviewable:end -->
2017-08-14 20:12:31 -05:00
Hiroyuki Ikezoe
03c5462cf5 Make vertical-align animatable between percentage and percentage or length. 2017-08-15 09:58:48 +09:00
Xidorn Quan
d3baa4fb3c Check pref when parsing :fullscreen pseudo-class 2017-08-15 10:48:35 +10:00
Xidorn Quan
89ba3553dc Apply line break suppression to text when in any ruby 2017-08-15 09:32:39 +10:00
Connor Brewster
221b099db4 Enqueue attribute changed callback when replacing attr 2017-08-14 16:13:55 -05:00
bors-servo
4d22af6136 Auto merge of #18072 - servo:we-are-leaving-babylon, r=emilio
Move some code out of animated_properties

<!-- 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/18072)
<!-- Reviewable:end -->
2017-08-14 07:51:34 -05:00
bors-servo
1573309b86 Auto merge of #18070 - emilio:orig-medium, r=heycam
stylo: only clear relevant origins when medium features change

Bug: 1389871
Reviewed-by: heycam

<!-- 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/18070)
<!-- Reviewable:end -->
2017-08-14 06:42:44 -05:00
Emilio Cobos Álvarez
bd74d7fd1d
style: Update bindings. 2017-08-14 12:46:45 +02:00
Emilio Cobos Álvarez
fd3d38326c
stylo: only clear relevant origins when medium features change.
Bug: 1389871
Reviewed-by: heycam
MozReview-Commit-ID: 6ocZc1u1TbU
2017-08-14 12:46:43 +02:00
Emilio Cobos Álvarez
f7eb46f484
style: Introduce OriginSet. 2017-08-14 12:46:41 +02:00
bors-servo
421a553799 Auto merge of #18069 - hiikezoe:scroll-snap, r=daisuke
Make scroll-snap-{coordinate, destination} discrete animation.

<!-- Please describe your changes on the following line: -->
https://bugzilla.mozilla.org/show_bug.cgi?id=1387941

---
<!-- 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

<!-- 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/18069)
<!-- Reviewable:end -->
2017-08-14 05:33:45 -05:00
bors-servo
b0422b8910 Auto merge of #18067 - heycam:fix-cascade, r=xidorn
geckolib: Return @font-face rules to Gecko in the expected cascade order.

From https://bugzilla.mozilla.org/show_bug.cgi?id=1389937.  Reviewed by Xidorn there.  Waiting until try server is back up and running before landing this, though.

<!-- 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/18067)
<!-- Reviewable:end -->
2017-08-14 04:19:34 -05:00
Hiroyuki Ikezoe
aaedf1cb84 Make scroll-snap-{coordinate, destination} discrete animation. 2017-08-14 17:25:42 +09:00
bors-servo
f93c6dfbd5 Auto merge of #18066 - dadaa:make-moz-appearance-animatable, r=hiro
Make -moz-appearance animatable

<!-- Please describe your changes on the following line: -->

---
<!-- 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

<!-- Either: -->
- [X] There are tests for these changes. The test code is patch part 2 in https://bugzilla.mozilla.org/show_bug.cgi?id=1382138

<!-- 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/18066)
<!-- Reviewable:end -->
2017-08-14 02:24:47 -05:00
Cameron McCormack
f26a7e9372 geckolib: Return @font-face rules to Gecko in the expected cascade order. 2017-08-14 11:38:43 +08:00
Boris Chiou
02277ce4a1 Fix the conversion from Perspective into ComputedMatrix.
We convert a perspective function into a ComputedMatrix, but we apply the
perspective length to a wrong matrix item. We should put it into m34,
instead of m43. m43 is for translate parameter Z.
2017-08-14 11:21:31 +08:00