Граф коммитов

51 Коммитов

Автор SHA1 Сообщение Дата
Mats Palmgren b15d020bef Bug 1581106 part 3 - [css-grid-2] Implement 'repeat(auto-fill, <line-names>)' in subgridded axis. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D46895

--HG--
extra : moz-landing-system : lando
2019-09-30 17:32:52 +00:00
Ting-Yu Lin f0a1298eaa Bug 1308587 Part 1 - Manually remove "-moz" prefixed multi-column properties in some tests. r=dholbert
In the next part, the patch generated by a script removes "-moz" prefix
to all multi-column properties.

However, some of the tests already have standard multi-column properties
specified. To avoid duplicating CSS multi-column rules in these
files (after applying the next part), I manually remove the prefixed
rules beforehand as many as possible.

Differential Revision: https://phabricator.services.mozilla.com/D44869

--HG--
extra : moz-landing-system : lando
2019-09-05 21:32:05 +00:00
Emilio Cobos Álvarez 1f3d6c04f2 Bug 1519958 - Refactor grid types to preserve repeat() at computed value time and use cbindgen. r=mats,boris
I'm _really_ sorry for the size of the patch. I tried to do this in two steps
but it was a lot of work and pretty ugly.

This patch makes us use cbindgen for grid-template-{rows,columns}, in order to:

 * Make us preserve repeat() at computed-value time. This is per spec since
   interpolation needs to know about repeat(). Except for subgrid, which did the
   repeat expansion at parse-time and was a bit more annoying (plus it doesn't
   really animate yet so we don't need it to comply with the spec).

 * Tweaks the WPT tests for interpolation to adopt the resolution at:
   https://github.com/w3c/csswg-drafts/issues/3503.

Trade-off here, as this patch stands, is that this change makes us use less
long-living memory, since we expand repeat() during layout, but at the cost of a
bit of CPU time during layout (conditional on the property applying though,
which wasn't the case before). It should be very easy to store a cached version
of the template, should this be too hot (I expect it isn't), or to change the
representation in other ways to optimize grid layout code if it's worth it.

Another trade-off: I've used SmallPointerArray to handle line-name merging,
pointing to the individual arrays in the style data, rather than actually
heap-allocating the merged lists. This would also be pretty easy to change
should we measure and see that it's not worth it.

This patch also opens the gate to potentially improving memory usage in some
other ways, by reference-counting line-name lists for example, though I don't
have data that suggests it is worth it.

In general, this patch makes much easier to tweak the internal representation of
the grid style data structures. Overall, I think it's a win, the amount of magic
going on in that mako code was a bit huge; it took a bit to wrap my head around
it.

This patch comments out the style struct size assertions. They will be
uncommented in a follow-up patch which contains some improvements for this type,
which are worth getting reviewed separately.

Also, this patch doesn't remove as much code as I would've hoped for because of
I tried not to change most of the dom/grid code for inspector, but I think a
fair bit of the nsGridContainerFrame.cpp code that collects information for it
can be simplified / de-copy-pasted to some extent. But that was a pre-existing
problem and this patch is already quite massive.

Differential Revision: https://phabricator.services.mozilla.com/D36598
2019-08-05 22:13:21 +02:00
Emilio Cobos Álvarez 6ed8680108 Bug 1559546 - Use atoms for grid line names. r=mats
The style system already atomizes all CustomIdent values, which means that we're
just wasting memory and CPU by doing string copies all over the place.

This patch fixes it. This also simplifies further changes to use as much of the
rust data structures as possible.

I had to switch from nsTHashtable to mozilla::HashTable because the former
doesn't handle well non-default-constructible structs (like NamedLine, which
now has a StyleAtom, which is not default-constructible).

Differential Revision: https://phabricator.services.mozilla.com/D35119

--HG--
extra : moz-landing-system : lando
2019-06-19 05:58:11 +00:00
Emilio Cobos Álvarez 841d3eea32 Bug 1559545 - Use servo for the representation of grid template areas. r=mats
Right now we do a lot of useless string copying. In order to avoid transcoding
to utf-16 during layout, make sure to use nsCString at a few related places.

I may revisit this since we're storing other line names as atoms in some places.
So it may be better to just use atoms everywhere.

But that'd be a different patch either way.

Depends on D35116

Differential Revision: https://phabricator.services.mozilla.com/D35117

--HG--
extra : moz-landing-system : lando
2019-06-18 22:29:58 +00:00
Shashank kaushik c329f1cc44 Bug 1532937 - Enable ESLint for dom/flex and dom/grid (manual changes). r=Standard8,smaug
Depends on D33345

Differential Revision: https://phabricator.services.mozilla.com/D33352

--HG--
extra : moz-landing-system : lando
2019-06-03 10:35:57 +00:00
Shashank kaushik 3ebe62f954 Bug 1532937 - Enable ESLint for dom/flex and dom/grid (automatic changes). r=Standard8,smaug
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D33345

--HG--
extra : moz-landing-system : lando
2019-06-03 10:42:12 +00:00
Micah Tigley 4a46d3a601 Bug 1531982 Part 2: Update test expectations to check that implicit line names from implicit named areas are assigned to lines. r=bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D21298

--HG--
extra : moz-landing-system : lando
2019-04-17 17:19:09 +00:00
Micah Tigley 37269bd347 Bug 1531982 Part 1: Assign correct line names to reversed implicit areas r=bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D21297

--HG--
extra : moz-landing-system : lando
2019-04-17 17:19:01 +00:00
Brian Grinstead 6515f97bcb Bug 1544322 - Part 1 - Remove the [type] attribute for one-liner <script> tags loading files in chrome://mochikit/content/ r=bzbarsky
This is an autogenerated commit to handle scripts loading mochitest harness files, in
the simple case where the script src is on the same line as the tag.

This was generated with https://bug1544322.bmoattachments.org/attachment.cgi?id=9058170
using the `--part 1` argument.

Differential Revision: https://phabricator.services.mozilla.com/D26812

--HG--
extra : moz-landing-system : lando
2019-04-15 20:56:58 +00:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Mark Banner b1c872942c Bug 1508980 - Add more .eslintrc.js files for dom/ and update .eslintignore. r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D12529

--HG--
extra : moz-landing-system : lando
2018-11-21 14:27:27 +00:00
Andi-Bogdan Postelnicu 88cc63910d Bug 1453795 - DOM - Initialize member fields in classes/ structures. r=peterv
--HG--
extra : rebase_source : 249fc26e50bded4e94f5effa4308af0f1e54b908
2018-06-16 17:21:46 +03:00
Jeff Gilbert 5b753da289 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Brad Werth e87dd19f09 Bug 1468416 Part 2: Update a grid API test to check fieldsets and buttons. r=mats
MozReview-Commit-ID: C12piKGougo

--HG--
extra : rebase_source : b7244170ee60877f0854e05a2a329de0b6c1c82a
2018-06-15 09:27:26 -07:00
Ciure Andrei 97d0135158 Backed out 2 changesets (bug 1468416) for failing nsGridContainerFrame CLOSED TREE
Backed out changeset f6f3c67e4d33 (bug 1468416)
Backed out changeset 55e1e865e626 (bug 1468416)
2018-06-22 21:37:15 +03:00
Brad Werth fdf5281c48 Bug 1468416 Part 2: Update a grid API test to check fieldsets and buttons. r=mats
MozReview-Commit-ID: C12piKGougo

--HG--
extra : rebase_source : 62ac02cd7dcdef77e249678002b849ee257bbeba
2018-06-15 09:27:26 -07:00
Brad Werth 1be59957e9 Bug 1456590 Part 2: Update test expectations to check that names from implicit named areas are not assigned to lines. r=mats
MozReview-Commit-ID: Bn3zGWkYSup

--HG--
extra : rebase_source : b462cc029b92d18ac63a7b6582c3dcf2d38c2056
2018-05-02 16:38:02 -07:00
Brad Werth 33507e6126 Bug 1456590 Part 1: Omit line names from implicitly named areas, to avoid confusion. r=mats
MozReview-Commit-ID: 3vK2MUeEuqw

--HG--
extra : rebase_source : 52b948982757381deed80879917135c887103b2b
2018-05-02 16:24:20 -07:00
Sebastian Hengst 0819f35e51 Backed out 4 changesets (bug 525063) on request from Andi. a=backout
Backed out changeset 516c4fb1e4b8 (bug 525063)
Backed out changeset 6ff8aaef2866 (bug 525063)
Backed out changeset bf13e4103150 (bug 525063)
Backed out changeset d7d2f08e051c (bug 525063)
2018-04-13 16:01:28 +03:00
Tristan Bourvon a3a77c0312 Bug 525063 - Initialize uninitialized class attributes in m-c. r=ehsan 2018-04-10 21:11:02 +02:00
Brad Werth 042dcb26b0 Bug 1423378 Part 3: Duplicate repeat auto-fit test into a repeat auto-fill test (with slightly different expected values). r=mats
MozReview-Commit-ID: AWmXfpRx7zG

--HG--
rename : dom/grid/test/chrome/test_grid_repeats.html => dom/grid/test/chrome/test_grid_repeat_auto_fit.html
2017-12-20 10:54:46 -08:00
Mats Palmgren 7097d46173 Bug 1423378 Part 2: Update tests to check line names around empty auto-fit grids. r=bradwerth 2017-12-16 14:56:00 +02:00
Brad Werth b61d32f5ef Bug 1423378 Part 1: Specially treat the explicit line names following a repeat auto-fit or auto-fill declaration to ensure they are always applied to the following line. r=mats
MozReview-Commit-ID: iFM5J6wRL6
2017-12-05 14:51:06 -08:00
Brad Werth 716259d509 Bug 1425954 Part 2: Update grid tests to check reporting of duplicated line names. r=mats
MozReview-Commit-ID: E0x7GXY9gUu

--HG--
extra : rebase_source : 0fdd4865cfd98fd93f6f7e41c0eb101ed3bc4ae0
2017-12-18 15:25:02 -08:00
Brad Werth e583e7216c Bug 1425954 Part 1: Strip out duplicate names when reporting line names via grid chrome API. r=mats
MozReview-Commit-ID: 9DW6EOFEpR6

--HG--
extra : rebase_source : 0a17162035230c48c9b4376eff4471275ee00724
2017-12-18 15:42:21 -08:00
Brad Werth 6ac9ae0497 Bug 1415670 Part 3: Extend Grid tests to check negativeNumber property. r=mats
MozReview-Commit-ID: 9tsjwCPNzmO

--HG--
extra : rebase_source : a91b26bc74c67b6ed73207f5d8c174e1218fb1b8
2017-11-08 16:38:31 -08:00
Brad Werth f2b7fe179b Bug 1415670 Part 2: Calculate negativeNumber for each GridLine. r=mats
MozReview-Commit-ID: D56jk7MbeIa

--HG--
extra : rebase_source : 344eff097ccce60224533c12ed68401934d7536a
2017-11-08 14:06:51 -08:00
Brad Werth b5a67ff8c1 Bug 1415670 Part 1: Add a negativeNumber property to GridLine in webidl. r=smaug
MozReview-Commit-ID: E3IycnsN6Ep

--HG--
extra : rebase_source : 47e6db76091c237aa3d40341427ff6c406405806
2017-11-08 13:25:16 -08:00
Bogdan Tara 09195ba0cc Backed out 3 changesets (bug 1415670) for failing chrome test dom/grid/test/chrome/test_grid_implicit.html r=backout on a CLOSED TREE
Backed out changeset 812aaf31c577 (bug 1415670)
Backed out changeset ec9fa6d9dca9 (bug 1415670)
Backed out changeset 92d2a5673bbc (bug 1415670)
2017-12-04 21:58:13 +02:00
Brad Werth ffbb9de0eb Bug 1415670 Part 3: Extend Grid tests to check negativeNumber property. r=mats
MozReview-Commit-ID: 9tsjwCPNzmO

--HG--
extra : rebase_source : 39c1c63a28a5126f1fc237a1fb765a0cdd822a0b
2017-11-08 16:38:31 -08:00
Brad Werth 884393d1ec Bug 1415670 Part 2: Calculate negativeNumber for each GridLine. r=mats
MozReview-Commit-ID: D56jk7MbeIa

--HG--
extra : rebase_source : 9ebbf7877126ca90fbb929e0472aff235221b898
2017-11-08 14:06:51 -08:00
Brad Werth 8d764e78da Bug 1416350 - Part 3: Add test to verify line numbers of grids with leading implicit tracks. r=mats
MozReview-Commit-ID: 8S8HMKhtWUP

--HG--
extra : rebase_source : 8fd4ed904a6d809af80f332a8e91155cf5a82394
extra : histedit_source : c9b06c066b4094ab4403c2ae8ed01b91ef3779a5
2017-11-10 14:10:33 -08:00
Brad Werth a0fd338be1 Bug 1416350 - Part 2: Correct logic for Grid API line numbering with leading implicit tracks. r=mats
MozReview-Commit-ID: 4tiwdqhb5hb

--HG--
extra : rebase_source : 58db5f92938cce5c7a658c2e89c8cde286452ea1
extra : histedit_source : 863399fbebc805b5d9a4718c5d77aefeca43dbdb
2017-11-10 09:46:22 -08:00
Brad Werth c9f2a7741b Bug 1373678 Part 3: Add line number checks to test_grid_implicit.html. r=dholbert
MozReview-Commit-ID: Bv5M3mtVyz5

--HG--
extra : rebase_source : 27bf6d55e046ea61212741cbb3126094dfcc8395
2017-06-16 11:03:33 -07:00
Brad Werth b1c8efe670 Bug 1373678 Part 2: Convert tabs to spaces in grid tests. r=dholbert
MozReview-Commit-ID: FLLZnDqnTez

--HG--
extra : rebase_source : 4a189fe4ef031d5d41d1ba89d7a31d68d95a06ac
2017-06-16 10:47:39 -07:00
Brad Werth 0ea02461da Bug 1373678 Part 1: Reduce grid line numbers by count of leading implicit lines, minimum 0. r=dholbert
MozReview-Commit-ID: 7RdautCGTn4

--HG--
extra : rebase_source : 537ec239115aa322c267a4a1519fe9a2574cc894
2017-06-16 11:19:36 -07:00
Joel Maher f297f17181 Bug 1339232 - annotate more dom/* moz.build files with BUG_COMPONENT. r=overholt
MozReview-Commit-ID: 2HbPxGkrVfv
2017-03-01 08:20:25 -05:00
Andi-Bogdan Postelnicu 454d1e68fa Bug 1308208 - remove redundant null check from GridLines::SetLineInfo. r=baku
MozReview-Commit-ID: 55lIk7Klh4I

--HG--
extra : rebase_source : b60609990e5a9c88cb9a6227af1f210cf1333ca1
2016-10-06 19:05:46 +03:00
Brad Werth ac8eac6caa Bug 1300877 - Expose removed grid auto-fit tracks to devtools API. r=mats, r=ehsan
MozReview-Commit-ID: 3E1au3BQyLw

--HG--
rename : dom/grid/test/chrome/test_grid_track_state.html => dom/grid/test/chrome/test_grid_repeats.html
2016-09-21 11:49:29 -07:00
Daniel Holbert 08f2ae369a (no bug) Drop whitespace on blank lines in test_grid_track_state.html (no review, whitespace-only)
MozReview-Commit-ID: 94YxIgaDaho
2016-09-23 10:53:56 -07:00
Brad Werth 4ca89baabe Bug 1281446 - Resolved value of grid-template-columns/rows now lists removed auto-fit tracks as 0px. r=mats
--HG--
extra : rebase_source : 1590c0690945a702ab519b6aa66c90e2a2e86222
2016-09-08 08:40:06 -07:00
Brad Werth 0c33f1af41 Bug 1297189 - Expose implicit grid areas via dev tools API. r=mats, r=bz 2016-09-02 16:28:27 -07:00
Brad Werth 3d92babadf Bug 1289200 - Adds GridAreas to grid css dev tools API. r=bz, mats 2016-08-23 13:34:51 -07:00
Tom Tromey 5538d692d3 Bug 1286877 - do not set c-basic-offset for python-mode; r=gps
This removes the unnecessary setting of c-basic-offset from all
python-mode files.

This was automatically generated using

    perl -pi -e 's/; *c-basic-offset: *[0-9]+//'

... on the affected files.

The bulk of these files are moz.build files but there a few others as
well.

MozReview-Commit-ID: 2pPf3DEiZqx

--HG--
extra : rebase_source : 0a7dcac80b924174a2c429b093791148ea6ac204
2016-07-14 10:16:42 -06:00
Brad Werth dde35eb992 Bug 1241932 - Expose decoded CSS grid line properties via a Chrome API. r=mats 2016-07-07 11:38:12 -07:00
Brad Werth e0d3269112 Bug 1241932 - Expose decoded CSS grid track properties in a Chrome API. r=heycam, r=khuey
--HG--
extra : rebase_source : 0c2a49236a2c71233a1ce6a92e50663b8a9f6238
2016-07-06 11:45:18 -07:00
Carsten "Tomcat" Book 1bb9877c16 Backed out changeset 3de5b79d7373 (bug 1241932) for bustage 2016-07-06 06:00:03 +02:00
Carsten "Tomcat" Book 2de695aebf Backed out changeset e98d1ac584d6 (bug 1241932) 2016-07-06 05:59:52 +02:00
Brad Werth 1656f9d629 Bug 1241932 - Expose decoded CSS grid line properties via a Chrome API. r=mats 2016-07-05 13:35:52 -07:00