Commit Graph

1009 Commits

Author SHA1 Message Date
Eduard Burtescu
67ca178f91 servo: Merge #12586 - Update Rust to 1.12.0-nightly (9316ae515 2016-07-24) (from servo:rustup); r=nox
Source-Repo: https://github.com/servo/servo
Source-Revision: 0be8e6857f4f767129dd694bf1e7e86060d307a4
2016-07-26 17:18:41 -05:00
Manish Goregaokar
0d7b7a23ad servo: Merge #12599 - Resync stylo bindings (from Manishearth:sync); r=heycam
Now at gecko-dev 13b9d03a21091cfcd797ab89decec2dde9114781

Source-Repo: https://github.com/servo/servo
Source-Revision: d6266c7cee0a8abb1d0f98ac183f744bcc925697
2016-07-26 10:07:15 -05:00
UK992
7aae8ab4c9 servo: Merge #12588 - Support tinyfiledialogs on Windows (from UK992:tinyfiledialogs); r=jdm
<!-- 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] These changes do not require tests because only add support for Windows

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 2de3b119a961942943280fa280c50a7a814de583
2016-07-25 08:14:09 -05:00
Emilio Cobos Álvarez
634c096b10 servo: Merge #12469 - style: Rewrite the restyle hints code to allow different kinds of element snapshots (from emilio:stylo); r=bholley
<!-- 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] These changes do not require tests because refactoring.

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

This is a rewrite for how style interfaces with its consumers in order to allow
different representations for an element snapshot.

This also changes the requirements of an element snapshot, requiring them to
only implement MatchAttr, instead of MatchAttrGeneric. This is important for
stylo since implementing MatchAttrGeneric is way more difficult for us given the
atom limitations. This also allows for more performant implementations in the
Gecko side of things.

I don't want to get this merged just yet, mainly because the stylo part is not
implemented, but I'd like early feedback from @bholley and/or @heycam: How do
you see this approach? I don't think we'll have much problem to implement
MatchAttr for our element snapshots, but... worth checking.

r? @heycam

Source-Repo: https://github.com/servo/servo
Source-Revision: 1e0321f7dde5f33f7d26bbd4f088622fa3660477
2016-07-21 16:54:34 -05:00
Josh Matthews
1ab2d6612c servo: Merge #12545 - Update ipc-channel (from jdm:ipcchannelbump); r=metajack
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12303
- [X] These changes do not require tests because we don't run automated tests on the platforms this affects

Source-Repo: https://github.com/servo/servo
Source-Revision: f8eab2b1658e687de03d58beb5b87fd0719509ef
2016-07-21 15:28:04 -05:00
Alan Jeffrey
528ece6c24 servo: Merge #12468 - Removed panic channel, replaced by integrated logging and issue reporting (from asajeffrey:constellation-remove-panic-channel); r=emilio
<!-- Please describe your changes on the following line: -->

Remove the previous ad hoc panic channel, replace it by an integrated logging and panicking mechanism, including crash reporting. All thread panics are now reported, not just content threads.

---
<!-- 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 #11838
- [X] These changes do not require tests because we don't test error reporting

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

Source-Repo: https://github.com/servo/servo
Source-Revision: df1b00d43db615244e8e4bcf8296ed51b64249ea
2016-07-21 11:20:37 -05:00
Manish Goregaokar
1aea46318e servo: Merge #12535 - Use Result instead of panicking when the resource dir can't be found (from Manishearth:try-resource); r=KiChjang
<!-- 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
- [x] These changes fix #12520 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because it's a refactoring

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

Source-Repo: https://github.com/servo/servo
Source-Revision: a39bd7db5ba26fa3c95e4bbbb5f1a358bc01965f
2016-07-21 04:08:49 -05:00
Manish Goregaokar
5eb45ceefb servo: Merge #12521 - Introduce safer layer of sugar for nsStyleUnion (from Manishearth:safer-coord); r=bholley
This routes (almost) all access to nsStyleUnion through a largely safe interface, CoordData.

It also introduces a corresponding Rust enum, CoordDataValue, which can be used when interacting with CoordData

LLVM should optimize the costs away in release mode. eddyb tested this a bit, and LLVM has no trouble threading matches together with inlining -- so all of the matches using enums here will have the same generated code as the old matches on the units.

Some unresolved questions:

Should I provide convenience methods like `set_coord`, `set_auto`, etc on CoordData? `.set_enum(CoordDataValue::Something)` should optimize down to the same thing, but the convenience methods look cleaner and won't load the optimizer as much.

Also, we're converting immutable references to mutable ones, which can be used to cause unsafety using some acrobatics. Perhaps a trait-based approach is better?
The issue is that in some places we only have a `&CoordData` (eg copy_from), but CoordData internally is `*mut`. It would be nice if CoordData could parametrize over its mutability, but Rust doesn't let us do that.

The alternate approach is to make CoordData a trait (also CoordDataMut). The trait requires you to implement `get_union()` and `get_unit()`, and gives you the rest of the functions for free. `nsStyleCoord` would directly implement both traits. `nsStyleSides` would have `data_at(idx)` and `data_at_mut(idx)` methods which return a struct `SidesData` containing a reference to the Sides and the index, which itself implements the `CoordData` and `CoordDataMut` trait (we need two traits here because there will have to be two `SidesData` structs).

I decided not to implement the traits approach first since it's pretty trivial to change this code to use traits, and the current design is more straightforward.

Thoughts?

r? @bholley

cc @emilio @heycam

Source-Repo: https://github.com/servo/servo
Source-Revision: 4a77cbdbb2fc1a4f163171356a7f5340e1237317
2016-07-21 03:05:56 -05:00
Emilio Cobos Álvarez
4853fe4b89 servo: Merge #12392 - style: Add support to test animations programatically (from emilio:test-animations); r=SimonSapin
<!-- 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
- [x] These changes fix #12120

<!-- Either: -->
- [x] There are tests for these changes OR

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

r? @SimonSapin for the style changes, @Ms2ger or @jdm for the dom and test changes

Source-Repo: https://github.com/servo/servo
Source-Revision: 14aeccc33ab44d706df86fbce67339218efe710c
2016-07-20 13:38:31 -05:00
Lars Bergstrom
d380c84980 servo: Merge #12507 - Remove clipboard crate to due disallowed usage of GPL code (from larsbergstrom:remove_clipboard); r=metajack
<!-- Please describe your changes on the following line: -->
Fixes #7578, removing usage of rust-clipboard, which contains a disallowed dependency on GPL code.

r? @metajack

---
<!-- 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 it's a dependency removal

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 46db988b906fbec0286fa07387bb34e76a5b3a94
2016-07-20 11:53:04 -05:00
Manish Goregaokar
5be1dfb192 servo: Merge #12517 - Resync bindings (from Manishearth:sync); r=heycam
Corresponds to the tmp-stylo-rebase branch on servo/gecko-dev

Still testing locally

Source-Repo: https://github.com/servo/servo
Source-Revision: 5832008c26d0858e0cc9e47f2abd43966ca05a54
2016-07-20 08:21:18 -05:00
Simon Sapin
c710b104be servo: Merge #12515 - Make the style crate more concrete (from servo:concrete-style); r=bholley
Background:

The changes to Servo code to support Stylo began in the `selectors` crate with making pseudo-elements generic, defined be the user, so that different users (such as Servo and Gecko/Stylo) could have a different set of pseudo-elements supported and parsed. Adding a trait makes sense there since `selectors` is in its own repository and has others users (or at least [one](https://github.com/SimonSapin/kuchiki)).

Then we kind of kept going with the same pattern and added a bunch of traits in the `style` crate to make everything generic, allowing Servo and Gecko/Stylo to do things differently. But we’ve also added a `gecko` Cargo feature to do conditional compilation, at first to enable or disable some CSS properties and values in the Mako templates. Since we’re doing conditional compilation anyway, it’s often easier and simpler to do it more (with `#[cfg(feature = "gecko")]` and `#[cfg(feature = "servo")]`) that to keep adding traits and making everything generic. When a type is generic, any method that we want to call on it needs to be part of some trait.

----

The first several commits move some code around, mostly from `geckolib` to `style` (with `#[cfg(feature = "gecko")]`) but otherwise don’t change much.

The following commits remove some traits and many type parameters through the `style` crate, replacing them with pairs of conditionally-compiled API-compatible items (types, methods, …).

Simplifying code is nice to make it more maintainable, but this is motivated by another change described in https://github.com/servo/servo/pull/12391#issuecomment-232183942. (Porting Servo for that change proved difficult because some code in the `style` crate was becoming generic over `String` vs `Atom`, and this PR will help make that concrete. That change, in turn, is motivated by removing geckolib’s `[replace]` override for string-cache, in order to enable using a single Cargo "workspace" in this repository.)

r? @bholley

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

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

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 2d01d41a506bcbc7f26a2284b9f42390d6ef96ab

--HG--
rename : servo/ports/geckolib/selector_impl.rs => servo/components/style/gecko_selector_impl.rs
rename : servo/ports/geckolib/values.rs => servo/components/style/gecko_values.rs
rename : servo/ports/geckolib/properties.mako.rs => servo/components/style/properties/gecko.mako.rs
2016-07-20 02:58:34 -05:00
Manish Goregaokar
a5176ec4b1 servo: Merge #12465 - Add bindings for calc() (from Manishearth:stylo-calc); r=heycam
This adds bindings for dealing with refcounted calc() values.

So far we can get/set them, but we don't yet have the ability to copy them around. I'll work on that next.

Corresponding gecko bindings at https://github.com/servo/gecko-dev/compare/stylo...Manishearth:stylo-calc?expand=1

f? @emilio @heycam

Source-Repo: https://github.com/servo/servo
Source-Revision: 37604401d027b991d9daf0b1df24408da36d5230
2016-07-19 20:57:10 -05:00
Ms2ger
3ae357217f servo: Merge #12506 - Rewrite a line in geckolib's properties.mako.rs to fix the build on windows (from servo:geckolib-win); r=larsbergstrom
Fixes #12505.

Source-Repo: https://github.com/servo/servo
Source-Revision: 3a9fca619d10c62be804f12b05de1df4afe556c9
2016-07-19 19:41:07 -05:00
Manish Goregaokar
79eb85ccb0 servo: Merge #12499 - Sync stylo bindings (from Manishearth:sync); r=emilio
Source-Repo: https://github.com/servo/servo
Source-Revision: 701e678d8eac3ebab7309759988832932f89af56
2016-07-18 23:37:27 -07:00
Xidorn Quan
ab54f9a291 servo: Merge #12498 - Support generating bindings for MSVC (from upsuper:msvc-bindgen); r=emilio
<!-- Please describe your changes on the following line: -->

This pull request includes several patches to the binding generating script to make it work with MSVC. The generated files are not updated because they may not be compatible with other platforms which the majority of developers are working on.

Only `regen.py` is modified. The two `.sh` files are not. Those files are very platform-specific and I don't think it's worth to make them work on Windows at all, and my hope is that we can get rid of those files and only use `regen.py`. I imagine the only left steps to get there are:

1. make clang version detectable via `bindgen` so that we get reliable clang version without needing to duplicate the library searching work (which has already been done in `clang-sys`)
2. checkout the git repo inside the python script and run `cargo build` there

BTW, it seems to me nightly Rust is not required to build `bindgen`, and thus we can probably get rid of the `multirust` detection. (Even if we need that, I think we should prefer `rustup` and optionally fallback to `multirust`. I know `rustup` is not yet available on Homebrew, though...)

---
<!-- 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 it is a change to binding generating script

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

r? @emilio

Source-Repo: https://github.com/servo/servo
Source-Revision: 2ce85f1cddb05689c231b1a17dfd2d374ad48377
2016-07-18 22:34:18 -07:00
Cameron McCormack
b4e35e0e34 servo: Merge #12487 - Add FFI glue for Gecko to implement 1-arg CSS.supports() with stylo (from heycam:supports-ffi); r=emilio
<!-- Please describe your changes on the following line: -->

This adds an FFI function for Gecko to call to implement the 1-arg version of `CSS.supports()`.  This will be useful for producing an automated analysis of CSS properties we lack support for in geckolib.  Corresponding Gecko bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1287382

r? @emilio

---
<!-- 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
- [X] These changes do not require tests because this is a geckolib-only change, and we don't have testing for that yet :(

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

Source-Repo: https://github.com/servo/servo
Source-Revision: f88ecda3628ec2af3a4e4c7fdebeda47b4008d6f
2016-07-18 21:25:31 -07:00
Glenn Watson
9d9fa28d20 servo: Merge #12497 - Update WR to get fix for texture atlas assert (from glennw:wr-update); r=emilio
<!-- 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: -->
- [ ] `./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 _____

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 877e480c47fabf400cfa2275aada9d6d9c678b9a
2016-07-18 18:46:14 -07:00
Cameron McCormack
fee8ba1d3d servo: Merge #12488 - geckolib: Support parsing style="" attributes longer than 255 characters (from heycam:style-len); r=SimonSapin
<!-- Please describe your changes on the following line: -->

This just fixes the bindings for a typo in `ServoBindings.h` in Gecko.  Corresponding Gecko bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1287383

r? @emilio

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

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

Source-Repo: https://github.com/servo/servo
Source-Revision: b36a3b2fee3e70c11af2bc24832e65510acb71ec
2016-07-18 08:48:30 -07:00
Shing Lyu
5e39e67d61 servo: Merge #11890 - Bug 10104 - Only restyle nodes that uses viewport percentage units on viewport size change (from shinglyu:viewport-percent-recalc); r=mbrubeck
<!-- Please describe your changes on the following line: -->
Bug 10104 - Only restyle nodes that uses viewport percentage units on viewport size change
---
<!-- 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 #10104 (github issue number if applicable).

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

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

Source-Repo: https://github.com/servo/servo
Source-Revision: d87ea67bf2efec45368d3e48634c6c16de7486ff
2016-07-17 20:46:24 -07:00
Alan Jeffrey
ca82078f35 servo: Merge #11841 - Send log messages to the constellation (from asajeffrey:constellation-logging); r=Manishearth
<!-- Please describe your changes on the following line: -->

Send all warnings and errors to the constellation. Warnings are bufferred up, and included in any subsequent error reports. Errors are reported in the same way as panics.

Note that this can't merge yet, as it needs https://github.com/rust-lang-nursery/log/pull/86 to land.

---
<!-- 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 #11776 (github issue number if applicable).
- [X] These changes do not require tests because we don't test crash reporting.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: a5cd4b95183da4ae9b754d9d4824bd23f4ad7eb8
2016-07-15 12:22:26 -07:00
Aravind Gollakota
78fcf243f3 servo: Merge #12441 - Implement referrer policy delivery by header (from aravind-pg:referrer-pol-header); r=jdm
Adds a new `Option<ReferrerPolicy>` field to Document and sets it appropriately in `ScriptThread::load` if a Referrer-Policy header is present.

r? @jdm

<!-- 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 #11860
- [X] There are tests for these changes

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

Source-Repo: https://github.com/servo/servo
Source-Revision: b382cc2103180f7dfd8df9c34970a95ed57a2d88
2016-07-15 11:25:43 -07:00
Andrew Mackenzie
624cea87a0 servo: Merge #12461 - Add a keyboard shortcut (Command + Q on Mac or Control + Q on other O… (from andrewdavidmackenzie:enable-quit-keyboard-shortcut); r=ConnorGBrewster
<!-- Please describe your changes on the following line: -->
Added code in window.rs to enqueue the Window::Quit event when the Command/Control + Q keyboard shortcut is detected IF keyboard shortcuts are enabled.
---
<!-- 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 #12422 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because there are no tests able to test keyboard shortcuts at the moment

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 6640115c9775e7177f79b1d6aa5fddceeeeb22e2
2016-07-15 09:33:06 -07:00
Shing Lyu
c913f7db5e servo: Merge #12442 - Implemented page-break-before/after for Stylo (from shinglyu:stylo-page-break); r=emilio
<!-- 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 _____

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 6bb5d0e8468797e057ce0f38f09338042823dd88
2016-07-14 22:47:31 -07:00
Alan Jeffrey
3502f92cc3 servo: Merge #12447 - All our Cargo.toml files should contain an MPL-2.0 license field (from asajeffrey:license-mpl-2.0); r=frewsxcv
<!-- Please describe your changes on the following line: -->

Added a `license = "MPL-2.0"` field to all our `Cargo.toml` files, and added a check to `test-tidy` that the license is present.

---
<!-- 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 #12434
- [X] There are tests for these changes

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 650d1d1185eecdc4c8b605bb0290ece7de839015
2016-07-14 09:33:18 -07:00
Manish Goregaokar
a3f6b93f58 servo: Merge #11851 - Add support for gecko-only array values; use for stylo (from Manishearth:stylo-autoarray); r=emilio
Doesn't yet work, because I can't grow nsTArrays from Rust. If anyone knows how to add bindings for that, let me know!

Thoughts on the design so far? Once this PR lands, all of the array-accepting background- properties can just use gecko_autoarray_longhand and some iterators in the geckolib implementation without changing much other code to work with arrays.

cc @emilio @bholley

Source-Repo: https://github.com/servo/servo
Source-Revision: ed985f75ecbb4f0df6231c58b2bfae1e82b255b6
2016-07-14 02:32:49 -07:00
Emilio Cobos Álvarez
77d1e7f00d servo: Merge #12339 - stylo: Implement dirtyness tracking for stylo (from emilio:stylo-node-dirtying); r=heycam
<!-- 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] These changes do not require tests because geckolib-only changes.

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

r? @bholley

Source-Repo: https://github.com/servo/servo
Source-Revision: 4a5a0a417bb55971fe70e7066c8d8c9a0ab36b3b
2016-07-13 19:48:54 -07:00
Josh Matthews
f1d49799db servo: Merge #12438 - Enable more DOM bindings inlining opportunities (from jdm:jsinline); r=metajack
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix (partially) #12354
- [X] These changes do not require tests because no automated performance tests

Source-Repo: https://github.com/servo/servo
Source-Revision: 6e8eec21bf4ea5eaebd5a72ce24c6171c6032794
2016-07-13 12:04:24 -07:00
Ms2ger
2e20fea88a servo: Merge #12432 - Update fnv (from servo:fnv); r=nox
Source-Repo: https://github.com/servo/servo
Source-Revision: 2df5d705e13f78afc8ceeb1b5333fc886e2691fa
2016-07-13 04:43:26 -07:00
cjkenned
678aec3267 servo: Merge #12429 - Remove assert statement from window (from cjkenn:12412); r=Ms2ger
<!-- 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
- [X] These changes fix #12412 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because simple removal of assert, no logic added or changed.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 39a0940d2e2b777a4ca33ea53b193125d273793a
2016-07-13 02:00:35 -07:00
Xidorn Quan
9a0abb1b59 servo: Merge #12427 - Generate atom bindings for msvc (from upsuper:msvc-atoms); r=emilio
<!-- Please describe your changes on the following line: -->
This patch adds code to Atom binding generating script to make it able to generate binding compatible with MSVC.

r? @bholley

---
<!-- 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 it is a geckolib-only change

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 82a1d09926269a65e4992e1498870c30e3276730
2016-07-12 22:57:38 -07:00
Manish Goregaokar
6e1c287d74 servo: Merge #12409 - Update clippy, improve clippy integration (from Manishearth:clippy); r=nox
This makes it much easier to run rustfix on servo

(rustfix is still pretty buggy though)

Source-Repo: https://github.com/servo/servo
Source-Revision: 74925460952ac070ff5e365b6fe6b886fd81861b
2016-07-12 07:29:25 -07:00
Anthony Ramine
9ca5148c48 servo: Merge #12366 - Bump ipc-channel to 0.4.0 (from nox:ipc); r=emilio
Source-Repo: https://github.com/servo/servo
Source-Revision: 5f188003baa2682cff29baf62e996474def588d1
2016-07-12 01:53:05 -07:00
Ms2ger
013bec0ca2 servo: Merge #12385 - Move arc_ptr_eq to style (from Ms2ger:arc_ptr_eq); r=SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: c3a8cbbd38570d4a9095ca94ee4a970956691051
2016-07-11 05:11:48 -07:00
Ms2ger
346257437f servo: Merge #12381 - Move some unit type definitions to style_traits (from Ms2ger:units); r=nox
Source-Repo: https://github.com/servo/servo
Source-Revision: 1c7bec4b493174742c579b67ddb6f5411892d3d2
2016-07-11 03:17:55 -07:00
Josh Matthews
d5309d3b13 servo: Merge #12374 - Improve performance of HTMLDivElement constructor (from jdm:jsup); r=Manishearth
These changes address two sources of performance loss seen while profiling in #12354. #12358 and https://github.com/rust-lang/rust/issues/34727 are still the biggest offenders, however.

---
- [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 we don't have performance tests and these are only optimizations

Source-Repo: https://github.com/servo/servo
Source-Revision: 01ec8491d3200d6710336da1bb0f4e01b49dc4bc
2016-07-10 08:18:27 -07:00
Simon Sapin
ce39d5cda4 servo: Merge #12319 - Use a stable compiler for build-geckolib (from servo:stable-geckolib); r=larsbergstrom+SimonSapin
<!-- 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
- [x] These changes fix #11815 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because CI already runs `./mach build-geckolib`

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

Source-Repo: https://github.com/servo/servo
Source-Revision: e50e4f99bf4668d183226251d8ea55fa36f72fe0
2016-07-08 16:20:14 -07:00
Xidorn Quan
dfc5204fe3 servo: Merge #12338 - Fix geckolib build for Windows (from upsuper:win-geckolib-fix); r=bholley
It contains several fixes to make `./mach build-geckolib` work on Windows.

Source-Repo: https://github.com/servo/servo
Source-Revision: 35a23bfef394fe451879f09979167b048a7bdc88
2016-07-08 11:14:48 -07:00
Ms2ger
aa21d1fab9 servo: Merge #12311 - Move the cache module out of util (from Ms2ger:cache); r=nox
Source-Repo: https://github.com/servo/servo
Source-Revision: d475a277eebaa7d91d1b070b169e205b4c533c4f

--HG--
rename : servo/tests/unit/util/cache.rs => servo/tests/unit/style/cache.rs
2016-07-08 07:46:00 -07:00
Bobby Holley
77781c7a5d servo: Merge #12329 - Geckolib: Trivial binding regeneration (from bholley:binding_regen); r=emilio
Mostly just want to get the blacklist fix in-tree.

r? emilio

Source-Repo: https://github.com/servo/servo
Source-Revision: bc45f85a60cc1f0e7a3419e84f809fcfa16d3baf
2016-07-07 22:04:04 -07:00
gozala
5631cd2452 servo: Merge #12302 - Update browserhtml version to 0.1.15 (from Gozala:bhtml@0.1.15); r=ConnorGBrewster
Update browserhtml version to 0.1.15

---
<!-- 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 it just updates dependency

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 0eed0e0b1e5ab2fc69ce64d5a0dd8c21d770092b
2016-07-07 17:20:02 -07:00
Jim Berlage
3c9046aeb4 servo: Merge #12299 - Fix up shell scripts (from jimberlage:fixup-scripts); r=emilio
<!-- Please describe your changes on the following line: -->
This brings these two scripts in line with the style guidelines.

---
<!-- 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 it's a small change to bring some shell scripts in line with the style guide

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 1f5c26a320af170a44f43dee4dcb076a6c5593e2
2016-07-07 16:24:52 -07:00
Matt Brubeck
cb17b2da08 servo: Merge #12294 - Update num_cpus, libc, openssl, threadpool, smallvec, string_cache, gleam, gl_generator, x11 (from mbrubeck:always-be-updating); r=KiChjang
Source-Repo: https://github.com/servo/servo
Source-Revision: d0ab03bb294b91e47ca929464ab71e7c42ff2e9a
2016-07-07 15:22:13 -07:00
Josh Matthews
57518b13d8 servo: Merge #11950 - Support non-QWERTY keyboards (from jdm:keylayout2); r=emilio
Using the ReceivedCharacter event from glutin, we can obtain the actual key characters that the user is pressing and releasing. This gets passed to the script thread along with the physical key data, since KeyboardEvent needs both pieces of information, where they get merged into a single logical key that gets processed by clients like TextInput without any special changes.

Tested by switching my macbook keyboard to dvorak and looking at the output of keypress/keyup/keydown event listeners, as well as playing with tests/html/textarea.html. Non-content keybindings like reload work as expected, too - the remapped keybinding triggers the reload action.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #4144
- [X] These changes do not require tests because I can't think of a way to test remapped keyboard input

Fixes  #11991.

Source-Repo: https://github.com/servo/servo
Source-Revision: 68fb9ebc413f9cfc1ad4ca578d904c164836db74
2016-07-06 02:51:50 -07:00
Emilio Cobos Álvarez
ee9d35391e servo: Merge #12212 - stylo: Move all binding-generator logic code to a python script (from emilio:stylo-regen-script); r=bholley
<!-- 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] These changes do not require tests because tooling

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

---

This not only makes us more consistent with the rest of the codebase but also:

 * Makes us repeat less code like common flags and all that stuff.
 * Reduces the noise of the build: You only get the output of the commands on
   failure or when you pass the -v flag.
 * Makes you able to select a single kind of build or multiple in the same
   place.

I've basically kept the regen.sh script because of the LIBCLANG_PATH checks, but
at least from Linux I don't need them anymore. Also, that logic could be moved
to the new script.

The whole point of this isn't only making it prettier and easier to use, but
also allowing me to write more complex logic in the binding generator scripts,
that I will probably need to integrate the DOM enum types we need for animations
and such easily (can't be just an include, because that pulls in another header
with the same name bringing a lot of DOM and IDL churn).

For reference, here's a successful regen round with the script:

```
./regen.py --target all /home/emilio/projects/moz/stylo/gecko/obj-x86_64-pc-linux-gnu/
[BINDGEN] structs::release in "/home/emilio/projects/moz/stylo/gecko/obj-x86_64-pc-linux-gnu/"... OK
[RUSTC]... OK
[RUSTC_TEST]... OK
test result: ok. 168 passed; 0 failed; 0 ignored; 0 measured
[BINDGEN] structs::debug in "/home/emilio/projects/moz/stylo/gecko/obj-x86_64-pc-linux-gnu/"... OK
[RUSTC]... OK
[RUSTC_TEST]... OK
test result: ok. 169 passed; 0 failed; 0 ignored; 0 measured
[BINDGEN] bindings::None in "/home/emilio/projects/moz/stylo/gecko/obj-x86_64-pc-linux-gnu/"... OK
```

---

r? @bholley

Maybe @jgraham and/or @Wafflespeanut want to take a look to criticize my (lack of) pythonism ;-)

Source-Repo: https://github.com/servo/servo
Source-Revision: e78459e6670b218970dfebb189a0c8ef7614951f
2016-07-06 00:12:58 -07:00
Bobby Holley
ba2f2c1399 servo: Merge #11886 - Refactor attribute handling to avoid marshalling attributes from Gecko into Servo (from bholley:attr_refactor); r=SimonSapin
This marshaling is slow, because Gecko stores attributes as UTF-16 and does not atomize them in all cases, and it turns out that the need for them in Servo is pretty minimal. With some refactoring across servo and rust-selectors we can fix this.

Source-Repo: https://github.com/servo/servo
Source-Revision: abdf2f28a0bd25a76a31b4fd2410c7a87448ed54
2016-07-05 18:55:36 -07:00
Simon Sapin
a7297026ea servo: Merge #12263 - Make geckolib possible to build on stable Rust (from servo:stable-geckolib); r=nox
<!-- Please describe your changes on the following line: -->

More for https://github.com/servo/servo/issues/11815

r? @nox

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

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 3d557b6f25eb9dbd084cb53bbc9a9cf93bad825b
2016-07-05 15:04:42 -07:00
mrmiywj
4b5a78e0a8 servo: Merge #11794 - when window gains focus, update mouse coordinate (from mrmiywj:update-mouse-coordinate-when-focus); r=KiChjang
<!-- 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: -->
- [ ] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #11130 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because these cannot be tested automated.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: d99ff8d8570dbf56b1812ef9451a6a8c3784c6c8
2016-07-05 10:18:49 -07:00
Gabriel Poesia
2ef28aab03 servo: Merge #11945 - Add mach build-stable to build with stable rustc (from gpoesia:master); r=SimonSapin
<!-- Please describe your changes on the following line: -->

Added mach subcommand (build-stable) to build servo and its dependencies using a stable version of rustc.

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

<!-- Either: -->
- [X] These changes do not require tests because they're in the build process. I've manually tested both build and build-stable several times and in different orders and it seems to work. If the mach subcommands are tested automatically somewhere, I'll be happy to add a test, but I couldn't find it.

This is an example of output I get, which is what I'd expect:

```plain
[gpoesia@gabriel-notebook servo]$ ./mach build
looking for rustc at /home/gpoesia/dev/servo/.servo/rust/2016-06-24/rustc-nightly-x86_64-unknown-linux-gnu/rustc/bin/rustc
Downloading Rust compiler...
Downloading Rust compiler: 100.0%
Extracting Rust compiler...
Rust compiler ready.
Downloading Host rust library for target x86_64-unknown-linux-gnu...
Downloading Host rust library for target x86_64-unknown-linux-gnu: 100.0%
Extracting Rust stdlib for target x86_64-unknown-linux-gnu...
Rust x86_64-unknown-linux-gnu libs ready.
Build completed in 0:00:01
[gpoesia@gabriel-notebook servo]$ ./mach build
Build completed in 0:00:02
[gpoesia@gabriel-notebook servo]$ ./mach build-stable
looking for rustc at /home/gpoesia/dev/servo/.servo/rust/rustc-1.9.0-x86_64-unknown-linux-gnu/rustc/bin/rustc
Rust compiler already downloaded. Use |bootstrap-rust --force| to download again.
Rust lib for target x86_64-unknown-linux-gnu already downloaded. Use |bootstrap-rust --force| to download again.
   Compiling log v0.3.6
   Compiling tenacious v0.2.1
   Compiling traitobject v0.0.1
   Compiling azure v0.4.6 (https://github.com/servo/rust-azure#4d72934a)
   Compiling crossbeam v0.2.9
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/tenacious-0.2.1/src/lib.rs:1:1: 1:42 error: #[feature] may not be used on the stable release channel
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/tenacious-0.2.1/src/lib.rs:1 #![feature(plugin_registrar, box_syntax)]
                                                                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/tenacious-0.2.1/src/lib.rs:3:1: 3:27 error: #[feature] may not be used on the stable release channel
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/tenacious-0.2.1/src/lib.rs:3 #![feature(rustc_private)]
                                                                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~
error: aborting due to 2 previous errors
Build failed, waiting for other jobs to finish...
error: Could not compile `tenacious`.

To learn more, run the command again with --verbose.
Build completed in 0:00:03
[gpoesia@gabriel-notebook servo]$ ./mach build-stable
looking for rustc at /home/gpoesia/dev/servo/.servo/rust/rustc-1.9.0-x86_64-unknown-linux-gnu/rustc/bin/rustc
Rust compiler already downloaded. Use |bootstrap-rust --force| to download again.
Rust lib for target x86_64-unknown-linux-gnu already downloaded. Use |bootstrap-rust --force| to download again.
   Compiling js v0.1.3 (https://github.com/servo/rust-mozjs#707bfb4f)
   Compiling serde_item v0.2.0
   Compiling encoding-index-tradchinese v1.20141219.5
   Compiling angle v0.1.0 (https://github.com/servo/angle?branch=servo#d0a2db05)
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/serde_item-0.2.0/src/lib.rs:3:43: 3:74 error: #[feature] may not be used on the stable release channel
/home/gpoesia/dev/servo/.cargo/registry/src/github.com-1ecc6299db9ec823/serde_item-0.2.0/src/lib.rs:3 #![cfg_attr(not(feature = "with-syntex"), feature(rustc_private, plugin))]
                                                                                                                                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error: aborting due to previous error
Build failed, waiting for other jobs to finish...
error: Could not compile `serde_item`.

To learn more, run the command again with --verbose.
Build completed in 0:00:37
[gpoesia@gabriel-notebook servo]$
```

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

Github issue: #11806
Building with current stable rust (1.9.0) still fails because of
feature pragmas in some dependencies (e.g. serde_item).

Source-Repo: https://github.com/servo/servo
Source-Revision: 1e1db061c039d6e7635310c0c728cfb959322249

--HG--
rename : servo/resources/shaders/debug_color.fs.glsl => servo/ports/stable-rust/src/lib.rs
2016-07-05 07:17:48 -07:00
Anthony Ramine
0f1c59e62d servo: Merge #12256 - Move some stuff from util to style (from nox:die-util-die); r=Ms2ger
Source-Repo: https://github.com/servo/servo
Source-Revision: bb916bb38bc4298477bfc8134b94dc906054bce1

--HG--
rename : servo/components/util/str.rs => servo/components/style/str.rs
rename : servo/components/util/tid.rs => servo/components/style/tid.rs
rename : servo/tests/unit/util/str.rs => servo/tests/unit/style/str.rs
2016-07-05 02:04:42 -07:00