Commit graph

27302 commits

Author SHA1 Message Date
Alan Jeffrey
ef033b8362 Implemented paint worklet properties. 2017-07-11 17:28:56 -05:00
bors-servo
de331c6bc8 Auto merge of #17654 - jyc:image-orientation, r=Manishearth
Make Servo's rounding of image-orientation values agree with Gecko's, and pass orientations directly as an enum instead of as angles.

Has been reviewed: https://reviewboard.mozilla.org/r/155336/

<!-- 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: -->
- [X] 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. -->

Bugzilla issue: https://bugzilla.mozilla.org/show_bug.cgi?id=1355380

<!-- 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/17654)
<!-- Reviewable:end -->
2017-07-11 11:22:26 -07:00
Jonathan Chan
e554146e2a Make Servo's rounding of image-orientation values agree with Gecko's,
and pass orientations directly as an enum instead of as angles.

Depends on a Gecko change to be subsequently landed in m-c.
2017-07-11 11:19:39 -07:00
bors-servo
bc1ac6e64c Auto merge of #17609 - asajeffrey:canvas-clear-state, r=jdm
Clear canvas thread state on recreation.

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

The canvas rendering context is cleared when it is recreated, but not the matching state in the canvas paint thread.

---
<!-- 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 #17533
- [X] These changes do not require tests because the css-paint-api tests test for this already.

<!-- 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/17609)
<!-- Reviewable:end -->
2017-07-11 06:40:33 -07:00
bors-servo
ee95bda3bf Auto merge of #17652 - Tremoneck:debug_key_mover, r=paulrouget
Move Ctrl-F12 keybindings outside of libservo

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

Creates a new WindowEvent called ToggleProfiller, when this Event is queued the profiler is toggled.
When Crtl + F12 are pressed the Event is queued.

---
<!-- 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 #17647 (github issue number if applicable).

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

<!-- 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/17652)
<!-- Reviewable:end -->
2017-07-11 01:17:20 -07:00
Tremoneck
6309d516bd Remove set_webrenderer_profiler_enabled in compositing/compositor.rs and servo/lib.rs and inlining this function in compositing/compositor.rs 2017-07-11 09:51:58 +02:00
bors-servo
42a6275bc2 Auto merge of #17660 - upsuper:moz-use-system-font, r=Manishearth
Serialize font longhands to -moz-use-system-font when using system font like what Gecko does

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

<!-- 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/17660)
<!-- Reviewable:end -->
2017-07-11 00:19:44 -07:00
Xidorn Quan
0e91f033cb Serialize font longhands to -moz-use-system-font when using system font like what Gecko does. 2017-07-11 17:19:12 +10:00
Tremoneck
e5e3748a46 Move WR profiler keybindings to glutin window, where the other keybindings
are located
2017-07-11 08:08:57 +02:00
bors-servo
8fa2a262dc Auto merge of #17658 - emilio:nesting-level, r=bholley
selectors: Avoid looking at MatchingMode if the selector isn't the topmost.

Also, switch the hover quirk to the same mechanism.

Bug: 1379696
Reviewed-By: bholley
MozReview-Commit-ID: KrmNqNyASf6

<!-- 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/17658)
<!-- Reviewable:end -->
2017-07-10 19:16:35 -07:00
Emilio Cobos Álvarez
1f2b79bc30
selectors: Avoid looking at MatchingMode if the selector isn't the topmost.
Also, switch the hover quirk to the same mechanism.

Bug: 1379696
Reviewed-By: bholley
MozReview-Commit-ID: KrmNqNyASf6
2017-07-11 03:52:07 +02:00
bors-servo
2ddbc92d90 Auto merge of #17655 - jdm:stylo-error-reporter, r=emilio
Hook up Stylo error reporter to Firefox devtools

Reviewed by @emilio in https://bugzilla.mozilla.org/show_bug.cgi?id=1352669.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [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/17655)
<!-- Reviewable:end -->
2017-07-10 18:13:44 -07:00
Josh Matthews
0b43d0072c stylo: Update rust-cssparser; extract more specific error types when reporting (bug 1352669). 2017-07-10 20:46:12 -04:00
Josh Matthews
a08371e8eb stylo: Create error reporters linked to documents (bug 1352669) 2017-07-10 20:46:08 -04:00
bors-servo
2475039e40 Auto merge of #17656 - hiikezoe:fix-assertion-in-add-weighted, r=birtles
Consider f64 epsilon for add_weighted portions.

This patch also degrade assert! to debug_assert! since crash reports don't show
us useful information so far (no assertion messages at all).

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

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
2017-07-10 17:03:19 -07:00
Hiroyuki Ikezoe
0d43281fad Consider f64 epsilon for add_weighted portions.
This patch also degrade assert! to debug_assert! since crash reports don't show
us useful information so far (no assertion messages at all).
2017-07-11 08:42:28 +09:00
bors-servo
4b91014b14 Auto merge of #17653 - hiikezoe:drop-AllowResolveStaleStyles, r=emilio
Drop allow resolve stale styles flag

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

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

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
2017-07-10 14:57:07 -07:00
Hiroyuki Ikezoe
8f1bb25807 Update bindings. 2017-07-11 06:47:17 +09:00
Hiroyuki Ikezoe
fa95c8513b drop AllowResolveStaleStyles flag
It's no longer used since bug 1357142.
2017-07-11 06:19:18 +09:00
bors-servo
5010df627d Auto merge of #17650 - jryans:link-transition-crash, r=hiikezoe
Pass through visited style for after change

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

<!-- 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/17650)
<!-- Reviewable:end -->
2017-07-10 11:33:04 -07:00
J. Ryan Stinnett
3463a9c210 Pass through visited style for after change
When a transition update is needed during restyling, `get_after_change_style` is
called to re-cascade without transition rules, and this style is then used for
primary styling instead of the style just computed.

`get_after_change_style` used to ignore visited styles, so this meant that if a
transition update was needed, visited styles were effectively dropped.

To fix the crash here, we pass through the existing visited styles when
re-cascading as part of `get_after_change_style`.

MozReview-Commit-ID: 4HBQAdeJ38B
2017-07-10 13:28:12 -05:00
bors-servo
2278a3f981 Auto merge of #17648 - hiikezoe:missing-keyframes, r=birtles
Do not fill computed values in missing 0%/100% keyframes in CSS Animation

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

https://bugzilla.mozilla.org/show_bug.cgi?id=1360398
---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
2017-07-10 02:31:35 -07:00
Hiroyuki Ikezoe
1a5e1c6255 Update bindings. 2017-07-10 18:27:19 +09:00
Hiroyuki Ikezoe
4834162e4a Pass null servo's computed values into ComputedKeyframeValues
With this patch series, test_cssanimation_missing_keyframes.html can pass now.
2017-07-10 17:18:25 +09:00
Hiroyuki Ikezoe
eb63511304 Do not fill computed values in missing keyframes for CSS animations during generating Keyframes 2017-07-10 17:17:51 +09:00
bors-servo
95a85a301f Auto merge of #17646 - upsuper:bug1372464, r=heycam
stylo: Use ComputedValues rather than element to get style rule list

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

<!-- 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/17646)
<!-- Reviewable:end -->
2017-07-09 20:07:41 -07:00
Xidorn Quan
7fd4b43aea Use ComputedValues rather than element to get style rule list. 2017-07-10 13:07:15 +10:00
bors-servo
82f65f6eb3 Auto merge of #17505 - cbrewster:less_blocking, r=asajeffrey,glennw
Remove unnecessary `recv` in the constellation

<!-- 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
- [ ] 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/17505)
<!-- Reviewable:end -->
2017-07-09 14:39:59 -07:00
bors-servo
00e366ac82 Auto merge of #17644 - emilio:invalidation-stylesheet-removals, r=heycam
stylo: Run the stylehseet invalidation pass also for stylesheet removals

People apparently do all sorts of silly stuff with stylesheets, see Google Inbox
in bug 1379203.

Bug: 1379433
Reviewed-By: heycam
MozReview-Commit-ID: 4x2d3glOFu8
2017-07-09 05:18:36 -07:00
Emilio Cobos Álvarez
43d58fc01a
stylo: Run the stylehseet invalidation pass also for stylesheet removals.
People apparently do all sorts of silly stuff with stylesheets, see Google Inbox
in bug 1379203.

Bug: 1379433
Reviewed-By: heycam
MozReview-Commit-ID: 4x2d3glOFu8
2017-07-09 14:17:19 +02:00
bors-servo
104e0b4730 Auto merge of #17640 - emilio:starts-with-ignore-ascii-case, r=stshine
style: Fix starts_with_ignore_ascii_case.

In particular, fix a panic when the input is not ASCII and we happen to index in
something that is not a char boundary.

This fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1379380

<!-- 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/17640)
<!-- Reviewable:end -->
2017-07-08 12:59:29 -07:00
bors-servo
85e5551ee9 Auto merge of #17099 - MortimerGoro:android_arm64, r=larsbergstrom
Support for Android arm64 compilations

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

This PR is the final step to adds support for Android arm64 compilations. See https://github.com/servo/servo/issues/11921 for previous work.

Fixes in this PR:
- Fix js dependency compilation: https://github.com/servo/rust-mozjs/pull/360
- Fix skia dependency link error: https://github.com/servo/skia/pull/136
- Fix blurdroid dependency compilation: https://github.com/szeged/blurdroid/pull/4
- Fix mio and net2 dependency compilations: https://github.com/carllerche/mio/pull/599
- Fix gcc compiler name in the fake linker
- Compile OpenSSL for aarch64 (update to stable 1.1.0 was required for this)

---
<!-- 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: -->
- [x] 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/17099)
<!-- Reviewable:end -->
2017-07-08 11:32:14 -07:00
Emilio Cobos Álvarez
9e00efc8a5
style: Make starts_with_ignore_ascii_case not lie if the strings are the same length. 2017-07-08 19:41:28 +02:00
Emilio Cobos Álvarez
d8a22d8bd7
style: Fix starts_with_ignore_ascii_case.
In particular, fix a panic when the input is not ASCII and we happen to index in
something that is not a char boundary.

This fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1379380
2017-07-08 19:32:11 +02:00
bors-servo
7a17de4fd0 Auto merge of #17639 - emilio:gdcs-rem, r=heycam
style: Avoid overriding the root font size from a getDefaultComputedStyle call

<!-- 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/17639)
<!-- Reviewable:end -->
2017-07-08 10:28:10 -07:00
bors-servo
41a7e6391b Auto merge of #17638 - rillian:mac-bindgen, r=emilio,gps
Fix build_gecko.rs for cross-macOS builds.

This was [reviewed](https://bugzilla.mozilla.org/show_bug.cgi?id=1368083) over on the gecko side, and is now ready to land. This adds an additional build-time `bindgen.toml` file whose compiler args are merged into the libclang invocation.

---
<!-- 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
- [x] These changes do not require tests because I *think* this is gecko-only. We'll find out.

<!-- 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/17638)
<!-- Reviewable:end -->
2017-07-08 09:24:08 -07:00
Emilio Cobos Álvarez
c2cc6b08f8
style: Avoid overriding the root font size from a getDefaultComputedStyle call.
MozReview-Commit-ID: 2WFyGj868fJ
2017-07-08 18:05:31 +02:00
Emilio Cobos Álvarez
5d03ba3cbe
style: Move root font size handling outside of the cascade.
And merge it with the rest of the code handling root font-size changes.

MozReview-Commit-ID: 3rW1C3mXiMd
2017-07-08 18:05:30 +02:00
Ralph Giles
ec49c4d8c8 Better bindgen error message when files are missing.
This is only slightly more informative because it doesn't give
the filename, but I think it's an improvement on the simple
unwrap() panic when we try to read a file which isn't there.

See also [Gecko bug 1368083](https://bugzilla.mozilla.org/show_bug.cgi?id=1368083).
2017-07-07 22:49:45 -07:00
Ralph Giles
8db2775ba6 Read bindgen flags from a generated file.
Bindgen needs some build-specific flags, like the -isysroot
passed to clang for the C++ compilation. Try to read
these from $objdir/layout/style/bindgen.toml which is
created by the Firefox build system, and merge them
into the config.

See also [Gecko bug 1368083](https://bugzilla.mozilla.org/show_bug.cgi?id=1368083).
2017-07-07 22:48:55 -07:00
bors-servo
1425ad1bab Auto merge of #17636 - upsuper:bug1378814, r=emilio
Don't return None in get_pseudo_style if not probing

This is the Servo side change of [bug 1378814](https://bugzilla.mozilla.org/show_bug.cgi?id=1378814).
2017-07-07 16:11:50 -07:00
Xidorn Quan
98075fcbfb Don't return None in get_pseudo_style if not probing 2017-07-08 09:10:47 +10:00
bors-servo
6e2e7151d8 Auto merge of #17632 - omakk:master, r=jdm
Clean up HTMLImageElement::handle_event

Reflects desired changes in #15832

<!-- Please describe your changes on the following line: -->
Cleans up `HTMLImageElement::handle_event` located in `components/script/dom/htmlimageelement.rs`

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

- [X] These changes do not require tests because this change maintains the same logic

<!-- 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/17632)
<!-- Reviewable:end -->
2017-07-07 11:21:16 -07:00
Omar Akkila
420a7878b9 Refactor HTMLImageElement::handle_event to be idiomatic
Clean up HTMLImageElement::handle_event

Area::hit_test now uses a reference instead of taking ownership

Fix trailing whitespace

Unalign => in match

Fix Area::hit_test tests to reflect updated function signature
2017-07-07 21:07:12 +04:00
bors-servo
327e72aa14 Auto merge of #17633 - servo:rustup, r=nox
Upgrade to rustc 1.20.0-nightly (696412de7 2017-07-06)

<!-- 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/17633)
<!-- Reviewable:end -->
2017-07-07 06:31:46 -07:00
Simon Sapin
665e9203a1 Upgrade to rustc 1.20.0-nightly (696412de7 2017-07-06) 2017-07-07 15:28:22 +02:00
bors-servo
eec51cdd57 Auto merge of #17619 - clarcharr:master, r=SimonSapin
Update parse-hosts.

The `parse-hosts` crate was recently updated so that it doesn't use any unstable features.

---
- [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 tests were already implemented.

<!-- 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/17619)
<!-- Reviewable:end -->
2017-07-06 23:34:13 -07:00
bors-servo
9268540e67 Auto merge of #17630 - canaltinova:grid-shorthand, r=wafflespeanut
stylo: Properly serialize grid shorthand

It was failing to serialize correctly when grid was `<'grid-template'>` or some different edge cases.

---
<!-- 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/17630)
<!-- Reviewable:end -->
2017-07-06 22:06:36 -07:00
Nazım Can Altınova
710637c53b stylo: Properly serialize grid shorthand 2017-07-06 21:44:42 -07:00
Clar Charr
f2942d217e ./mach cargo update -p cfg-if 2017-07-06 21:37:58 -04:00