Commit graph

6165 commits

Author SHA1 Message Date
paavininanda
87e7b1ee7a Correct default selectionStart and selectionEnd 2018-02-23 02:37:11 +05:30
paavininanda
b517410a34 Revert "Correct default Selectionstart and SelectionEnd"
This reverts commit b2c1f89b93.
2018-02-23 01:55:21 +05:30
bors-servo
9c484452c0
Auto merge of #20068 - paavininanda:autocloseworker, r=jdm
added AutoCloseWorker for closing related workers when a page/another worker is closed.

<!-- Please describe your changes on the following line: -->
Followed steps as suggested in issue.
Error is not yet resolved!

---
<!-- 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 #17977 (https://github.com/servo/servo/issues/17977?).

<!-- Either: -->
- [x] These changes do not require tests because it will have manual test case.

<!-- 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/20068)
<!-- Reviewable:end -->
2018-02-22 13:34:55 -05:00
bors-servo
f6463c89d5
Auto merge of #20051 - jonleighton:prevent-invalid-selections, r=jdm
Disallow mutating the internals of TextInput

The TextInput::assert_ok_selection() method is meant to ensure that we
are not getting into a state where a selection refers to a location in
the control's contents which doesn't exist.

However, before this change we could have a situation where the
internals of the TextInput are changed by another part of the code,
without using its public API. This could lead to us having an invalid
selection.

I did manage to trigger such a situation (see the test added in this
commit) although it is quite contrived. There may be others that I
didn't think of, and it's also possible that future changes could
introduce new cases. (Including ones which trigger panics, if indexing
is used on the assumption that the selection indices are always valid.)

The current HTML specification doesn't explicitly say that
selectionStart/End must remain within the length of the content, but
that does seems to be the consensus reached in a discussion of this:

https://github.com/whatwg/html/issues/2424

The test case I've added here is currently undefined in the spec which
is why I've added it in tests/wpt/mozilla.

<!-- 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/20051)
<!-- Reviewable:end -->
2018-02-22 11:47:40 -05:00
Nupur Baghel
36991b9d79 added autoclose worker 2018-02-22 21:34:53 +05:30
yurket
8d4aa585a6 Adjust paint worklet tests after changing implementation according to new specification 2018-02-22 15:16:27 +03:00
yurket
203ff9fd25 Enable css-paint-api WPT tests and remove forked duplicates
wpt tests replace all but 3 tests from forked _mozilla_ tests. These 3 were removed from wpt repo
in commit de7719144e1c7da2ca8d6a543bec428fcfd3c30f, so we can remove all forked _mozilla_
css-paint-api tests
2018-02-22 13:21:41 +03:00
yurket
c7e3def9b2 Move paintWorklet from "Window" to "CSS" according to new specification
Relevant discussion: https://github.com/w3c/css-houdini-drafts/issues/410
2018-02-22 13:21:41 +03:00
WPT Sync Bot
726b56aa12 Update web-platform-tests to revision e92532746b7615dcccdfa060937a87664816b1db 2018-02-21 21:39:38 -05:00
bors-servo
0b4ea018b0
Auto merge of #20034 - Manishearth:table-backgrounds, r=mbrubeck
Handle table cell backgrounds during display list generation for <table>

Fixes #19788

<!-- 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/20034)
<!-- Reviewable:end -->
2018-02-21 12:00:03 -05:00
bors-servo
a0fff37de3
Auto merge of #20094 - servo-wpt-sync:wpt_update_20-02-2018, r=jdm
Sync WPT with upstream (20-02-2018)

Automated downstream sync of changes from upstream as of 20-02-2018.
[no-wpt-sync]

<!-- 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/20094)
<!-- Reviewable:end -->
2018-02-21 01:06:32 -05:00
WPT Sync Bot
a57b869a58 Update web-platform-tests to revision 58462b6f92aab3eea03ad1ea70923855889ed1e2 2018-02-20 21:46:54 -05:00
Manish Goregaokar
7de29d0ac4 Update test expectations 2018-02-20 14:00:58 -08:00
Emilio Cobos Álvarez
4c979a8346
style: Remove a unit test that relies on disabled-by-default properties. 2018-02-20 14:21:34 +01:00
WPT Sync Bot
8a6476740e Update web-platform-tests to revision 8fed98324bc133df221d778c62cbff210d43b0ce 2018-02-19 21:42:17 -05:00
bors-servo
4454e81878
Auto merge of #20041 - paavininanda:mutflags, r=jdm
Added extra bool in Window object to know about its Mutation Observers

<!-- Please describe your changes on the following line: -->
- Added Cell<bool> type variable in Window object to know whether its mutation observers are present/absent
- Added get and set functions for this variable
- Added supporting test files to check for performance

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

<!-- Either: -->
- [x] There are tests for these changes, but these are manual tests for checking correctness of added code

<!-- 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/20041)
<!-- Reviewable:end -->
2018-02-16 12:16:55 -05:00
Nupur Baghel
a1fd6c39a2 Added extra bool in Window object to know about its Mutation Observers 2018-02-16 21:52:29 +05:30
bors-servo
a1c79d21c1
Auto merge of #20059 - servo-wpt-sync:wpt_update_15-02-2018, r=jdm
Sync WPT with upstream (15-02-2018)

Automated downstream sync of changes from upstream as of 15-02-2018.
[no-wpt-sync]

<!-- 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/20059)
<!-- Reviewable:end -->
2018-02-16 10:47:22 -05:00
bors-servo
a6113af873
Auto merge of #20054 - ferjm:innertext.setter, r=emilio
Implement element.innerText setter

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #16107
- [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/20054)
<!-- Reviewable:end -->
2018-02-16 05:38:38 -05:00
Jon Leighton
32f781234a Disallow mutating the internals of TextInput
The TextInput::assert_ok_selection() method is meant to ensure that we
are not getting into a state where a selection refers to a location in
the control's contents which doesn't exist.

However, before this change we could have a situation where the
internals of the TextInput are changed by another part of the code,
without using its public API. This could lead to us having an invalid
selection.

I did manage to trigger such a situation (see the test added in this
commit) although it is quite contrived. There may be others that I
didn't think of, and it's also possible that future changes could
introduce new cases. (Including ones which trigger panics, if indexing
is used on the assumption that the selection indices are always valid.)

The current HTML specification doesn't explicitly say that
selectionStart/End must remain within the length of the content, but
that does seems to be the consensus reached in a discussion of this:

https://github.com/whatwg/html/issues/2424

The test case I've added here is currently undefined in the spec which
is why I've added it in tests/wpt/mozilla.
2018-02-16 11:24:12 +01:00
Fernando Jiménez Moreno
d64bf623f6 Implement element.innerText setter 2018-02-16 11:20:53 +01:00
WPT Sync Bot
44c252aede Update web-platform-tests to revision d04c0d50dbbf7752c27957005a5a659701b781ad 2018-02-15 21:54:40 -05:00
Anthony Ramine
6d8650078a Fix an error in executorservo.py
```
TypeError: make_hosts_file() takes exactly 2 arguments (0 given)
```
2018-02-15 11:33:47 -05:00
WPT Sync Bot
9882351fad Update web-platform-tests to revision 6be7f242bbcec40802cda8f670bbec31570dd077 2018-02-14 21:14:13 -05:00
bors-servo
2b9acb12dd
Auto merge of #20050 - paavininanda:NewTests, r=jdm
Adding left over tests using DRY coding

<!-- 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 add the tests using DRY technique to reduce redundant code for https://github.com/servo/servo/pull/19963

<!-- 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/20050)
<!-- Reviewable:end -->
2018-02-14 15:59:51 -05:00
paavininanda
06f0ad1be7 Adding tests with DRY coding technique 2018-02-15 01:48:48 +05:30
WPT Sync Bot
432648745e Update web-platform-tests to revision 1e4fe87a7f01c0b5c614c8f601ffa68b4a00662a 2018-02-13 21:19:19 -05:00
bors-servo
b1d3d6f632
Auto merge of #19975 - paulrouget:killbhtml, r=mbrubeck,emilio
Kill browserhtml

Fixes https://github.com/servo/servo/issues/19971

<!-- 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/19975)
<!-- Reviewable:end -->
2018-02-13 04:54:47 -05:00
bors-servo
9e64008e75
Auto merge of #19754 - ferjm:innertext, r=mbrubeck
Implement element.innerText getter

<!-- 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/19754)
<!-- Reviewable:end -->
2018-02-13 03:41:48 -05:00
Paul Rouget
d09bb477f9 remove mozbrowser tests 2018-02-13 09:40:07 +01:00
Fernando Jiménez Moreno
2a4535f43e Implement element.innerText getter 2018-02-13 09:12:00 +01:00
paavininanda
b2c1f89b93 Correct default Selectionstart and SelectionEnd 2018-02-10 17:46:29 +05:30
WPT Sync Bot
b524b7c279 Update web-platform-tests to revision 6d85a3b422cab97d032ad3db47cb741ca364185f 2018-02-08 21:30:07 -05:00
dan-robertson
426bd83a0d
Merge branch 'master' into freetype2 2018-02-08 16:59:09 +00:00
bors-servo
aa497bd31b
Auto merge of #19987 - servo-wpt-sync:wpt_update_07-02-2018, r=jdm
Sync WPT with upstream (07-02-2018)

Automated downstream sync of changes from upstream as of 07-02-2018.
[no-wpt-sync]

<!-- 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/19987)
<!-- Reviewable:end -->
2018-02-08 09:21:12 -05:00
WPT Sync Bot
e0fb3fc586 Update web-platform-tests to revision d6d3f7267e817925131675bfc203c62bda96febe 2018-02-07 23:14:20 -05:00
Glenn Watson
0a2ea7381f Update WR (various transform, hit-testing related fixes). 2018-02-08 11:22:03 +10:00
WPT Sync Bot
a4b4c8e015 Update web-platform-tests to revision b7ee88243f64e6c7f2d00c163bd3bc501e4db7ef 2018-02-06 21:05:52 -05:00
Dan Robertson
58d1969c5a Added a test for font selection
The test picks a font and makes a table asking for that font at every
possible weight/stretch combination. One should expect the table
entries to get bolder from right to left and wider from top to bottom.
2018-02-06 20:46:20 +00:00
bors-servo
36eb711d3b
Auto merge of #19946 - paavininanda:Issue18613, r=jdm
Change Offset_to_text_point function and add unit tests

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

<!-- Either: -->
- [x] Added unit tests and web platform tests

<!-- 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/19946)
<!-- Reviewable:end -->
2018-02-06 15:11:54 -05:00
paavininanda
7b58fb5fdd Changed offset_to_text_point function and added unit tests for the same 2018-02-07 01:18:50 +05:30
bors-servo
8f24005e17
Auto merge of #19933 - mrobinson:update-wr, r=emilio
Update WebRender

This allows servo to use the ExternalScrollId API from WebRender fixing
some issues related to duplicate scroll root ids.

Fixes #17176.
Fixes #19287.
Fixes #19648.

<!-- 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 #17176, #19287, and #19648.

<!-- 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/19933)
<!-- Reviewable:end -->
2018-02-06 09:12:58 -05:00
Martin Robinson
99eb457fc7 Update WebRender
This allows servo to use the ExternalScrollId API from WebRender fixing
some issues related to duplicate scroll root ids.

Fixes #17176.
Fixes #19287.
Fixes #19648.
2018-02-06 15:10:35 +01:00
bors-servo
9faf0cdce5
Auto merge of #19956 - servo:derive-all-the-things, r=emilio
Generate some PropertyDeclaration methods by hand 🐉🐲

We rely on https://github.com/rust-lang/rfcs/pull/2195 to make some enums share the same discriminants by definition.

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

<!-- 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/19956)
<!-- Reviewable:end -->
2018-02-06 08:12:33 -05:00
Anthony Ramine
5195eb38f2 Make all PropertyDeclaration variants have only one field 2018-02-06 13:45:18 +01:00
WPT Sync Bot
210ff0c02a Update web-platform-tests to revision bb1f35100ad0aedeeb6897dd640b360f80498027 2018-02-05 22:35:36 -05:00
WPT Sync Bot
cd5bf022bd Update web-platform-tests to revision 68a256f49be380ca4add535ce8ece9de28820e6b 2018-02-04 21:05:56 -05:00
bors-servo
f84e9236ae
Auto merge of #19929 - terracotaPie:master, r=jdm
Verify that all values in include.ini represent real directories

<!-- Please describe your changes on the following line: -->
wpt manifest(include.ini) contains directories as headers. With this test in **test-tidy** we check if they are present in respective wtp test folders.

---
- [X] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [X] These changes fix #19703

<!-- 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/19929)
<!-- Reviewable:end -->
2018-02-03 22:39:23 -05:00
Timur Borkhodoev
1027644cb6 Remove a expected fail test 2018-02-03 15:52:26 -05:00
Timur Borkhodoev
607306af91 Add update-wpt generated ini 2018-02-02 17:37:19 -05:00