Commit Graph

1902 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
2bc468b78a servo: Merge #20597 - style: Implement the non-functional :host selector (from emilio:host); r=xidorn
Kinda tricky because :host only matches rules on the shadow root where the rules
come from. So we need to be careful during invalidation and style sharing.

I didn't use the non_ts_pseudo_class_list bits because as soon as we implement
the :host(..) bits we're going to need to special-case it anyway.

The general schema is the following:

 * Rightmost featureless :host selectors are handled inserting them in the
   host_rules hashmap. Note that we only insert featureless stuff there. We
   could insert all of them and just filter during matching, but that's slightly
   annoying.

 * The other selectors, like non-featureless :host or what not, are added to the
   normal cascade data. This is harmless, since the shadow host rules are never
   matched against the host, so we know they'll just never match, and avoids
   adding more special-cases.

 * Featureless :host selectors to the left of a combinator are handled during
   matching, in the special-case of next_element_for_combinator in selectors.
   This prevents this from being more invasive, and keeps the usual fast path
   slim, but it's a bit hard to match the spec and the implementation.

   We could keep a copy of the SelectorIter instead in the matching context to
   make the handling of featureless-ness explicit in match_non_ts_pseudo_class,
   but we'd still need the special-case anyway, so I'm not fond of it.

 * We take advantage of one thing that makes this sound. As you may have
   noticed, if you had `root` element which is a ShadowRoot, and you matched
   something like `div:host` against it, using a MatchingContext with
   current_host == root, we'd incorrectly report a match. But this is impossible
   due to the following constraints:

    * Shadow root rules aren't matched against the host during styling (except
      these featureless selectors).

    * DOM APIs' current_host needs to be the _containing_ host, not the element
      itself if you're a Shadow host.

Bug: 992245
Reviewed-by: xidorn
MozReview-Commit-ID: KayYNfTXb5h
Source-Repo: https://github.com/servo/servo
Source-Revision: cb754b262747e7cab794411df55588f0f0b30b5e

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 2ebbb2578ff9dbadfe905ae501cd52bd61a9fe9a
2018-04-09 06:41:59 -04:00
Xidorn Quan
2d686a4869 servo: Merge #20592 - Use Servo code to check whether a property is inherited (from upsuper:is-inherited); r=emilio
This is the Servo side change of [bug 1452534](https://bugzilla.mozilla.org/show_bug.cgi?id=1452534).

Source-Repo: https://github.com/servo/servo
Source-Revision: 0f20e82690db5e865b12eef2bed2d787d4b02280

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 536cd69f38f86c5810659a2fe5aa0c6e2ea91d8a
2018-04-09 05:19:48 -04:00
Emilio Cobos Álvarez
295a8f58b3 servo: Merge #20584 - style: Add an FFI function to see if an element is display: contents (from emilio:bye-undisplayed-maps); r=bz
Bug: 1303605
Reviewed-by: bz
Source-Repo: https://github.com/servo/servo
Source-Revision: a35c9e71a3d5d9ef87de4cfba542117a280014e1

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 226530d7f19f66bf7d5ee399fce94a29cb0fb9b9
2018-04-07 07:54:41 -04:00
Jonathan Watt
02a31f33e2 servo: Merge #20572 - Stop using NS_STYLE_FONT_WEIGHT_NORMAL and NS_STYLE_FONT_WEIGHT_BOLD (from jwatt:master); r=emilio
The Servo side of the changes for
https://bugzilla.mozilla.org/show_bug.cgi?id=1452040

- [X] `./mach build -d` does not report any errors
- [X] `./mach build-geckolib` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

- [ ] There are tests for these changes OR
- [X] These changes do not require tests because it's a trivial change to internal constants

Source-Repo: https://github.com/servo/servo
Source-Revision: a0bdba73e3f0dd52a74f75bc8191f52c3af2a62c

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 068e6ebeaa11ce792ccbb034045a008dd5df029e
2018-04-06 09:22:33 -04:00
Xidorn Quan
2120e04223 servo: Merge #20559 - Remove some unused stuff in nsCSSValue (from upsuper:cleanup-nscssvalue); r=emilio
This is the Servo side change of [bug 1448763](https://bugzilla.mozilla.org/show_bug.cgi?id=1448763).

Source-Repo: https://github.com/servo/servo
Source-Revision: 044f19d91433c706857a9ddd958425225c3a683e

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 3fb3e9f489c86a3db8e8c4caa008665657147689
2018-04-05 05:37:39 -04:00
Xidorn Quan
c798790c4b servo: Merge #20541 - Use Servo data to back @counter-style rule in Gecko (from upsuper:counter-style); r=emilio
This is the Servo side changes of [bug 1449068](https://bugzilla.mozilla.org/show_bug.cgi?id=1449068).

Source-Repo: https://github.com/servo/servo
Source-Revision: 8c35be94c2910a50bbb7106449bab4e231697aea

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : f48b41f3df283812cdc926befcdb5af996e0d444
2018-04-04 19:34:06 -04:00
Xidorn Quan
3698b17162 servo: Merge #20519 - Use Servo data to back @font-face rule in Gecko (from upsuper:font-face-rule); r=emilio
This is the Servo side change of [bug 1449087](https://bugzilla.mozilla.org/show_bug.cgi?id=1449087).

Source-Repo: https://github.com/servo/servo
Source-Revision: 34b13dac66b48790003ccd069f4636f1def77e7d

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : a02d3471f240efcb43cfcbf55442da919e967983
2018-04-03 19:33:59 -04:00
Fabrice Desré
b83287a8e8 servo: Merge #20483 - Cleanup ports/servo to only rely on libservo (from fabricedesre:port-cleanup); r=paulrouget
<!-- Please describe your changes on the following line: -->
When using `ports/servo` as a starting point for an embedding, it's easier if it only relies on the `libservo` crate and not directly on `components` ones. Since `libservo` reexports all the modules we need, it's a straightforward fix.

---
<!-- 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 There are no relevant tests, and no real code change.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: f7a495afa71d6053d9843677f1f53b8002bc8194

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 764b5fac18fc8ca927b4ee7c835f22912445b489
2018-03-31 03:05:34 -04:00
Bastien Orivel
6cccb0a3eb servo: Merge #20465 - Bump env_logger to 0.5 and log to 0.4 in every servo crate (from Eijebong:log); r=SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: 12d82fe621947c2b29b12d9c9e9a81b0f4baa117

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 2700938c990b720e4f47039361e256bc239a55df
2018-03-28 15:08:52 -04:00
Xidorn Quan
6ec573da45 servo: Merge #20456 - Remove nsCSSPseudoClasses and friends (from upsuper:remove-nscsspseudoclasses); r=emilio
This is the Servo side change of [bug 1449097](https://bugzilla.mozilla.org/show_bug.cgi?id=1449097) and [bug 1449089](https://bugzilla.mozilla.org/show_bug.cgi?id=1449089).

Source-Repo: https://github.com/servo/servo
Source-Revision: 97c12bd3927c057d5610b0295f0e8320b64af5e5

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : f63d725bb89e33c3dafa18714e4b77d8958675c6
2018-03-27 18:51:48 -04:00
Anthony Ramine
eb01729955 servo: Merge #20414 - Implement gl.getParameter(gl.ALIASED_POINT_SIZE_RANGE) (from servo:webgl); r=emilio
Source-Repo: https://github.com/servo/servo
Source-Revision: 782d4d4af61b7c9f60dfb494f8a5bfb6407945d2

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 1146f8db91b95babd6368db052c8c926a76c7774
2018-03-24 14:58:38 -04:00
Emilio Cobos Álvarez
30afff82d1 servo: Merge #20386 - style: Rename StyleContext to ComputedStyle (from emilio:computed-style-rename); r=jwatt
Bug: 1447483
Reviewed-by: jwatt
MozReview-Commit-ID: KATZ6DkmpVY
Source-Repo: https://github.com/servo/servo
Source-Revision: 563f0ec8245d6ff4d7d200c30655f90f5bdfed64

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 686981ffd66ff5827b3bd09fb846cf8abbb6e403
2018-03-22 13:48:24 -04:00
Paul Rouget
a0dd2872af servo: Merge #20228 - Ports refactoring (from paulrouget:ports_refactor); r=jdm
Depends on https://github.com/servo/servo/pull/20071 and https://github.com/servo/servo/pull/19895

This PR does 3 things:
1) merge all the embedder coordinates callbacks into one
2) hand the embedder messages directly to the embedder
3) split the embedder code in 2 files: window.rs and browser.rs

This is in preparation for tabs support in `ports/`. We want to separate the windowing logic (glutin stuff) and the browsing logic (tabs management, browsers state, etc). It's also easier to bypass the callbacks and directly handle events.

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

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

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 2c3a783c1ade39c9580be7452598e1c97d2a990f
2018-03-22 08:10:45 -04:00
OJ Kwon
33d6f805b4 servo: Merge #20327 - fix(keyevent): do not emit default ignorable codepoint (from kwonoj:fix-ignore); r=paulrouget
<!-- Please describe your changes on the following line: -->
This PR intends to update `KeyEvent` emit behavior around #18130. Issue https://github.com/servo/servo/issues/17146#issue-233361568 briefly explains what's happening in servo currently - there are KeyboardInput event emitted for separated key (modifier, and `V` in case of paste) and there are also `ReceivedCharacter` event corresponds to `\u{0016}`.

`0x0016` is unicode representation of `Synchronous Idle` (https://en.wikipedia.org/wiki/Synchronous_Idle), belong under category of `Default Ignorable` charater in unicode range doesn't have visual representation (http://www.unicode.org/L2/L2002/02368-default-ignorable.pdf). Currently servo forwards all of emitted event from `winit` including this, eventually leads into double execution of control event.

In this change try to omit default ignorable charater , if given char received is within range of ignorable do not dispatch `KeyEvent`. Once those are omitted, current event handling logic already takes care of key event with correct modifier state so duplicated event handling won't occur.

For implementation perspective, `std::char` in Rust doesn't seem to support `isIdentifierIgnorable` like other platform does (i.e: https://msdn.microsoft.com/en-us/library/aa285330(v=vs.60).aspx / https://docs.oracle.com/javase/7/docs/api/java/lang/Character.html) - so does quick, naïve range comparison check based on unicode range specified in spec, similar to halfbuzz and other does. (https://github.com/harfbuzz/harfbuzz/blob/master/src/hb-unicode-private.hh#L134)

Lastly, this is indeed behavior of `winit` to emit all characters by default. *Why not try to make upstream changes instead?* While I've been reading through issues in `winit`, issue like https://github.com/tomaka/winit/issues/350 trying to emit ignorable character by its intention (delete key `ReceivedCharacter` is also under category of default ignorable) and let each consumer application handles it as needed. I assume it'll cause breaking changes in winit's design if it intends to omit those characters, instead tried to make application-level changes.

Couple of consideration for review

- Is it desired changes to not emit `KeyEvent` for default ignorable chars? Do we rather want mapping / or restoring back to original char as @paulrouget mentioned in https://github.com/servo/servo/issues/17146#issue-233361568?
- Any better, recommended approach to detect unicode char range?
- Maybe try to make upstream changes to `winit` still, like having configuratble way to opt-in(out) those char event?

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

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____
- This PR has been locally tested on Windows, Linux machines.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 28c92db26837531e75327cff7727ed8bc1c70b48

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 2dcf517220e225cf478e056432d0b84c0b2b5d9b
2018-03-22 02:00:09 -04:00
Bastien Orivel
3fffb92cb4 servo: Merge #20378 - Bump parking_lot to 0.5 (from Eijebong:parking_lot); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 1c2bed5a6909268c85d61ec73b2ab63602294eb1

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 00ad02dad5a420567cd74fc2190ede9e1b056a75
2018-03-21 14:16:57 -04:00
Paul Rouget
ec298ee6f2 servo: Merge #20374 - Fix mouse click (from paulrouget:hittest); r=glennw
<!-- Please describe your changes on the following line: -->

PR #20071 broke mouse click on hidpi screens.

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 1594d0b54cc3f8488c244632e1cce2a62a75ed42

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : f90206931affb62e03b55b376010e8a5988e7c82
2018-03-21 05:46:09 -04:00
Jonathan Watt
7a9e9059be servo: Merge #20351 - Add Servo_Property_IsShorthand to geckolib/glue.rs (from jwatt:master); 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 _____

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 42305e3c366fb06dcf21d18f3f111eb8ee139701

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 46b036aaa53fb88efce06e2ed29d1036d35967ec
2018-03-19 12:53:48 -04:00
Emilio Cobos Álvarez
ef7d849ac7 servo: Merge #20339 - style: Remove unsound Atom From implementations (from emilio:atom-from-dead-beef); r=nox
Fixes #20158

Source-Repo: https://github.com/servo/servo
Source-Revision: b47224dbcce2974e6f572b284cba1e2f5393b95d

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 68a732c7b4fa6564e34427438a019385391585b9
2018-03-19 06:11:14 -04:00
UK992
010548064a servo: Merge #20316 - Windows: Add icon to servo.exe (from UK992:win32-icon); r=jdm
Based on https://github.com/servo/servo/pull/11969

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 840c44e2a8db05c11d5c87a7ce644001732b0cfa

--HG--
rename : servo/components/servo/servo.exe.manifest => servo/ports/servo/platform/windows/servo.exe.manifest
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 595aeb4fc84adb07427d24b960e92b8bee6b7507
2018-03-18 14:31:35 -04:00
Paul Rouget
0b85384c36 servo: Merge #20071 - Use typed coordinates more (from paulrouget:typedsize); r=glennw
Requires https://github.com/servo/servo/pull/19895

We use Size2D and Point2D across compositing, constellation and script, loosing the type of pixels we use (DevicePixel, DeviceIndepententPixel or CSSPixel) along the way, which might lead to bugs like `window.outerHeight` not taking into account the page zoom (using DeviceIndepententPixel instead of CSSPixel).

This should make the situation a bit better.

---
<!-- 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 we can't zoom in a test

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

Source-Repo: https://github.com/servo/servo
Source-Revision: fc90e613d8851b663e3304d713b2ca08aa397bf4

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : c1b61b486feff98c01c3ffed639b84bae093bdae
2018-03-16 17:18:24 -04:00
OJ Kwon
7ba09e30ed servo: Merge #20315 - feat(window): bind hotkey to trigger capture event (from kwonoj:feat-webrender-capture); r=jdm
<!-- Please describe your changes on the following line: -->
Relates to #20295.

This PR intends to expose additional hotkey to window to allow capture webrender. Internally it adds one new `WindowEvent::CaptureWebRender` for those purpose. I took some liberty to make some decisions around which need to be reviewed & updated in PR.

- `Ctrl-shift-3` is binded to hotkey to follow described in Gecko's behavior. Is it good to go?
- Maybe do not need to create new event `CaptureWebRender` but reuse `ToggleWebRenderDebug`, having additional `WebRenderDebugOption` values?
: This sounds more right path for me, but `capture` isn't really `toggle` behavior to include capture into it.
- Capturing will create `capture_webrender` in cwd, creates new folder inside each time new capture stored
: Maybe it'd better to expose new cmdline args allow overrides, or some better way else. I took the simple approach to generate path without asking for it.

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

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____
- This change has manually verified on local machines (mac, windows, linux).

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

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

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 7325d6d0b12a105da15a7e4fdd803535152bd68a
2018-03-16 13:49:17 -04:00
OJ Kwon
9b3a782c85 servo: Merge #20303 - refactor(window): reference winit where applicable (from kwonoj:refactor-winit); r=SimonSapin
<!-- Please describe your changes on the following line: -->
This is nearly first changes to rustlang code and I suspect I could make possible mistakes lot, please point me anything if need to be updated. 🙏

This PR intends to update codebase per #20299 , mostly followed suggestion around https://github.com/servo/servo/issues/20299#issuecomment-373171416 to update reference to use `winit` where applicable. Confirmed local build / check works correctly for updated references.

---
<!-- 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 #20299 (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. -->

Source-Repo: https://github.com/servo/servo
Source-Revision: 5f408422941b87e936880074f99a69fbdeebd131

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : e3ed7e0ceaa3d36a1dd07b14b04af761e8e8d90d
2018-03-15 15:45:48 -04:00
Paul Rouget
4955984079 servo: Merge #19895 - unfork glutin (from paulrouget:unfork); r=paulrouget
I'm taking over #19120.

Fix #18918.

Beside the change in the API, I had to rewrite main loop.

At this point, we should have a very similar behavior as servo-glutin.

Source-Repo: https://github.com/servo/servo
Source-Revision: c9f60c5a6778fe47cae85fcd88cb38257a220bb1

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : e3ef5fbc5962e96c48a1340e589054aa2086bb92
2018-03-08 21:00:13 -05:00
Matt Brubeck
f0cce88058 servo: Merge #20245 - Disable logging in bindgen to reduce code size (from mbrubeck:logging); r=emilio
This disables bindgen's `logging` feature, which builds `env_logger`
with default features, including regex support.  Disabling it allows
Gecko to build `env_logger` without the `regex` crate, reducing code
size.

Part of https://bugzilla.mozilla.org/show_bug.cgi?id=1444097

---

- [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 only change unused build config

Source-Repo: https://github.com/servo/servo
Source-Revision: 46dfc3536472c1b68be501dc5b37ff6fdd7dba35

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 202a5a3a0f0b83dab018f0f641d88e6c9ade9f22
2018-03-08 13:36:04 -05:00
Xidorn Quan
1f119c6d9c servo: Merge #20238 - Construct URLValue eagerly and share it between specified value and style structs (from upsuper:url-value); r=emilio
This is the Servo side change of [bug 1443046](https://bugzilla.mozilla.org/show_bug.cgi?id=1443046).

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

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 6c4306304c77f6feb169b335ec66f0b78b5f1763
2018-03-08 08:06:35 -05:00
Paul Rouget
fdb8f25cb4 servo: Merge #20182 - Prompt URL on Cmd/Ctrl-L (from paulrouget:ctrl_l); r=jdm
<!-- Please describe your changes on the following line: -->

The `sanitize_url` code is very naive. I'm sure we can do better.
This ServoShell issue describes the problem: https://github.com/paulrouget/servoshell/issues/59

I can fix that now if someone can help me figure out how to tell if a string is a valid url which is just missing a scheme. Or we can do that in a follow up.

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

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

Source-Repo: https://github.com/servo/servo
Source-Revision: ec3aa8bd7a985b26f894a73f9b84fc53a005d453

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 7c313a0358fb1b5923cad0221afdfae11ba11b03
2018-03-04 12:48:30 -05:00
Jonathan Kew
9137f16912 servo: Merge #20191 - style: Make 'font' shorthand reset 'font-variation-settings' property (from jfkthame:font-shorthand-resets-variation-settings); r=emilio
As required by the spec: https://drafts.csswg.org/css-fonts-4/#font-prop

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

Basically, make font-variation-settings work in the same way as font-feature-settings
already does.

- [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).

- [ ] There are tests for these changes OR
- [X] These changes do not require tests because font-variation-settings isn't supported in servo; it is implemented here for gecko/stylo, and will be tested by mozilla-central mochitests.

Source-Repo: https://github.com/servo/servo
Source-Revision: 1783e41f34c75bc7dfb158b4aa2628fd945eceb3

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : ccc26bb6fcbce339c34504dc3c493cee879970a0
2018-03-04 11:50:56 -05:00
Emilio Cobos Álvarez
0bb1806dc2 servo: Merge #20193 - style: Remove more rustc_has_pr45225 stuff (from emilio:needless-stuff-is-needless); r=nox
Also cleans up references to a fixed issue.

Source-Repo: https://github.com/servo/servo
Source-Revision: d09ea8476e68ff131d71bc78a2c6c324679b90d5

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : a065c7a872724c2802092c569b93aba720eeac32
2018-03-04 10:41:54 -05:00
Andrei Cristian Petcu
1d48511773 servo: Merge #20175 - #20174 removed the option and unwrap (from andreicristianpetcu:remove_optional_from_default_config_dir); r=jdm
I removed the useless option and the need for unwrap from default_config_dir

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #20174 (github issue number if applicable).
- [X] These changes do not require tests because they are used at build time.

Source-Repo: https://github.com/servo/servo
Source-Revision: 48ff3965cc2e483a33d457e3ddaf9ad10007c275

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 35c998111a39669ae544b501ba781cdb9407e627
2018-03-02 14:39:37 -05:00
Josh Matthews
173e864112 servo: Merge #20153 - Update glutin, skia, and azure (from jdm:glutinup); r=SimonSapin
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #19901

Source-Repo: https://github.com/servo/servo
Source-Revision: 23e95906347c4b6d0d1ccd1ce12ff5206c349a9a

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 806d322a34be21e05a94e6a7cadbfb78cb0e8b9d
2018-03-01 10:20:05 -05:00
Bobby Holley
cfbe8920ca servo: Merge #20146 - Stylo: Pass an explicit parent SheetLoadData for child stylesheet loads (from bholley:explicit_load_data); r=bholley
https://bugzilla.mozilla.org/show_bug.cgi?id=1441896

Source-Repo: https://github.com/servo/servo
Source-Revision: e8f77861a9af8d88ba62625838a10d63c74d22ed

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 10643d7df19b8b97d27a5081dec6816b120afa1a
2018-02-28 11:32:00 -05:00
Emilio Cobos Álvarez
1319d160ae servo: Merge #20138 - style: Only expose longhands to rust via iterators (from emilio:longhand-iterator); r=nox
The key here is that we only filter longhands if the shorthand is accessible to
content and vice-versa. This prevents the bug that prevented me to land this
patch before, which was us not expanding properly chrome-only shorthands.

Source-Repo: https://github.com/servo/servo
Source-Revision: a0be3a7fae2730bfef52db94db7f3af14b60be67

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 2afb50b62cab334fcec0cdcccd793abca8fdb3ec
2018-02-28 06:28:41 -05:00
Bastien Orivel
ba431a7ec0 servo: Merge #20140 - Bump euclid to 0.17 (from Eijebong:euclid); r=SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: 38298336beb4ef8873cae22919bd8bee0f6496d4

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 0fc60971a64e0c8fb9be4503a54298f9ecb8cf8b
2018-02-28 04:14:32 -05:00
Emilio Cobos Álvarez
8fff47a007 servo: Merge #20133 - style: Make Shadow DOM not use XBL anymore (from emilio:kill-xbl); r=xidorn
Bug: 1425759
Reviewed-by: xidorn
MozReview-Commit-ID: Jf2iGvLC5de
Source-Repo: https://github.com/servo/servo
Source-Revision: a7f38f0f32e2a01dfd3d415fd34d246957bede63

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 628ac3fd9871e10371a3b4c3cd432c7977af4441
2018-02-27 05:47:29 -05:00
Emilio Cobos Álvarez
d178469908 servo: Merge #20082 - style: Cleanup always-false argument to Servo_ResolveStyleLazily (from emilio:ignore-existing-styles); r=bholley
I changed this setup in https://bugzilla.mozilla.org/show_bug.cgi?id=1414999,
because it was totally unsound.

Source-Repo: https://github.com/servo/servo
Source-Revision: 691f3be24a6fcc90ae7d0b9b0783abf8674e1b0f

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 9a6a2851157d91b46caf11d52b534268f3a24cba
2018-02-21 06:09:15 -05:00
Emilio Cobos Álvarez
d015fb39b1 servo: Merge #20081 - style: More serialization tweaks (from emilio:more-longhand-stuff); r=nox
This still doesn't fix everything. In particular, we need to check whether the
subproperty will be enabled in Longhands and LonghandsToSerialize too.

I haven't decided yet on what's the best way to do that.

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

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : f69fc629a34488a51df7323b320b52ee2da65ab1
2018-02-20 23:49:19 -05:00
Xidorn Quan
666ef26b7f servo: Merge #20070 - Add sizeof for AuthorStyles (from upsuper:authorstyles-size); r=bholley,njn
This is the Servo side change for [bug 1438497](https://bugzilla.mozilla.org/show_bug.cgi?id=1438497).

Source-Repo: https://github.com/servo/servo
Source-Revision: a98da8ce939e8afe7bac737ac02e3bcb226a1ea9

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 31f23b7517b49570f311b34d4c27f8eda9f2a0c1
2018-02-18 23:13:10 -05:00
Emilio Cobos Álvarez
f2afd33bae servo: Merge #20065 - style: Cleanup GeckoElement::note_explicit_hints (from emilio:note-stuff); r=nox
What it's doing is not so complicated.

Source-Repo: https://github.com/servo/servo
Source-Revision: d423e54d58d6cced950896eed1957ee2989f4eee

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 5f2eb141315f4abbc2e2340950d43679aaf79f42
2018-02-16 15:33:48 -05:00
Emilio Cobos Álvarez
946bc4825a servo: Merge #20061 - style: Make XBL / Shadow DOM use something more light-weight than a Stylist (from emilio:author-styles); r=xidorn
Introduce AuthorStyles, which is just a struct aggregating stylesheets +
CascadeData, with a quirks_mode parameter because XBL sucks so bad.

Bug: 1436059
Reviewed-by: xidorn
MozReview-Commit-ID: 7q99tSNXo0K
Source-Repo: https://github.com/servo/servo
Source-Revision: 504b901cc82db5c5e02e157cec9753f7c297ac2c

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 79252144a91938156e03e4bf1be76988a14beeed
2018-02-16 09:54:06 -05:00
Xidorn Quan
5e807fd261 servo: Merge #19925 - Use cstr macro for ffi literal strings (from upsuper:cstr); r=emilio
Use `cstr!()` macro with `CStr` to ensure that literal strings used with FFI is properly nul-terminated to avoid cases like #19915.

Source-Repo: https://github.com/servo/servo
Source-Revision: 5af219e8188f2e657c5711eb5def4c8e8065e29d

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : fb6a22714c7b8ff534181e54c265fca24da7873b
2018-02-14 06:49:38 -05:00
Xidorn Quan
742625c2c0 servo: Merge #20042 - Integrate font-variation-settings descriptor with stylo (from upsuper:font-variation-desc); r=emilio
This is the Servo side change for [bug 1435984](https://bugzilla.mozilla.org/show_bug.cgi?id=1435984).

Source-Repo: https://github.com/servo/servo
Source-Revision: 27cd4f7b5387f188570a355c58bf87b9a029d76e

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : de2178dad493accc07bda8dd4cded94a002377a8
2018-02-13 19:16:34 -05:00
Emilio Cobos Álvarez
308e8cbfd9 servo: Merge #20038 - style: Avoid an intermediate buffer in Servo_Shorthand_AnimationValues_Serialize (from emilio:no-need-for-strings); r=nox
Source-Repo: https://github.com/servo/servo
Source-Revision: 4c3f1756da1373e9eef33716c9a93b0bb0559241

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 5e9b4f0230a2ad74e3c9d84fb32067db8ad17c8c
2018-02-13 12:06:02 -05:00
Emilio Cobos Álvarez
fbc79ce711 servo: Merge #20039 - style: Use consistent formatting for functions in the glue file (from emilio:indent); r=nox
I'm tired of only drive-by fixing them :)

Source-Repo: https://github.com/servo/servo
Source-Revision: 7e31ae35e1036467e25484ab30132f8bd49f0ee8

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 36caa8cd45913ca5b0068fef7b234a4992e03c57
2018-02-13 10:25:30 -05:00
Paul Rouget
23c32a1748 servo: Merge #19975 - Kill browserhtml (from paulrouget:killbhtml); r=mbrubeck,emilio
Fixes https://github.com/servo/servo/issues/19971

Source-Repo: https://github.com/servo/servo
Source-Revision: b1d3d6f6324394f0e9f17b027fef24420d829b5c

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 15c8b4050d084908ae58fb9dbf6dfcc179698d76
2018-02-13 04:54:47 -05:00
Emilio Cobos Álvarez
4bc28644f9 servo: Merge #20018 - style: Handle quirks-mode changes correctly (from emilio:quirks-mode-flush); r=xidorn
The reason why bug 1355721 regressed this is because in non-e10s we definitely
flush before parsing the standards quirks-mode. And bug 1355721 introduced an
unconditional UpdateStylistIfNeeded, unless the counter style / font
equivalents.

That means that the stylist wouldn't remain on its initial state after the first
flush, which itself means that when the compat mode changed, the UA and user
rules were already on the stylist with the quirks mode keys. That makes
class-names be keyed in ascii lowercase.

After that no user style changed, so no rebuild happens for the cascade data in
the user origin, so we keep looking at the wrong keys indefinitely.

We should try to avoid the flush there and ensure that by the time we create a
pres shell the quirks mode is already up-to-date...

Bug: 1394233
Reviewed-by: xidorn
MozReview-Commit-ID: 25dD2bca3tN
Source-Repo: https://github.com/servo/servo
Source-Revision: 2ec0b50ebc65f04a49420e15267f564d36d5ada1

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 763cfe74f08d44b02b166be1c2077b3f4d97e8f5
2018-02-11 13:19:02 -05:00
Xidorn Quan
9f999d9c1d servo: Merge #20013 - Return whether property was removed from Servo_DeclarationBlock_RemoveProperty (from upsuper:remove-prop-bool); r=bzbarsky
This is the Servo side change of [bug 1435139](https://bugzilla.mozilla.org/show_bug.cgi?id=1435139).

Source-Repo: https://github.com/servo/servo
Source-Revision: afaa51b99387df084da421a738f204fefaebfbab

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : f0a0b143d2750de047e62ab4ee940e791c2826b1
2018-02-10 03:59:43 -05:00
Emilio Cobos Álvarez
d9b65d628d servo: Merge #20004 - style: Add infrastructure to have a standalone author stylesheet collection (from emilio:author-sheet-collection); r=nox
Right now Gecko uses a whole `Stylist` for stuff like XBL / Shadow DOM.

That's not great, because it has tons of unrelated logic, and also eats up a lot of memory. Also, it prevents us to optimize style changes in shadow hosts the same way we do for the document.

These patches mostly rejigger stuff around so that you can define a `DocumentStylesheetSet` and then an `AuthorStylesheetSet`, which would contain just the Shadow DOM sheets / XBL resource sheets.

It still doesn't introduce any use for the later, but that will come later.

There's a patch in this PR that requires Gecko changes, posted in https://bugzilla.mozilla.org/show_bug.cgi?id=1436798.

Source-Repo: https://github.com/servo/servo
Source-Revision: 6b1a74672d6b9d9c55b027b147b0a6eb8f727bfd

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 35cd629f88c24439c615e283265dbb78d33279b7
2018-02-09 17:18:08 -05:00
Manish Goregaokar
a17da12d3c servo: Merge #19994 - Remove traversal telemetry (from Manishearth:rm-telemetry); r=upsuper
Source-Repo: https://github.com/servo/servo
Source-Revision: e654afbc3e47d97835328e6131ef51b2e27e3409

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 9c2646dea983c0d03022566fa69a04897146cfc8
2018-02-08 08:10:09 -05:00
Emilio Cobos Álvarez
b081657510 servo: Merge #19973 - style: Rework how media feature changes are handled for XBL (from emilio:media-feature-change); r=xidorn
Bug: 1435939
Reviewed-by: xidorn
Source-Repo: https://github.com/servo/servo
Source-Revision: e57319a7345eded057555f55f801e5f2c413f5b9

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 6da4b2d236318d13aad4a8f4c1211f733901fa96
2018-02-07 08:02:34 -05:00
janczer
4e2c0a5eb3 servo: Merge #19970 - Change debug assertions to specific ones (from janczer:change_debug_assertions); 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
- [X] These changes fix #19962 (github issue number if applicable).

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

Source-Repo: https://github.com/servo/servo
Source-Revision: 5d209a70ab11cd0ce6c7e086091112570c6e259d

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : c837bee3dbbf93357f6553a2a356685a094d8e3e
2018-02-07 06:20:36 -05:00