Now that we have UTF8String in the WebIDL, we can remove quite a few of the
conversions. Do that, and lift the remaining string conversions up as needed.
Also deindent Servo_ComputeColor while touching it.
Most of the remaining copies are because either bug 1606994, or because they're
WebIDL attributes that we still need to serialize back as UTF-16 (bug 1606995).
Differential Revision: https://phabricator.services.mozilla.com/D58687
--HG--
extra : moz-landing-system : lando
cbindgen understands references, there's no need to use raw pointers here and
then unwrapping or unsafely dereferencing them.
Also remove one unused function while at it.
Differential Revision: https://phabricator.services.mozilla.com/D58708
--HG--
extra : moz-landing-system : lando
This cleans up and also allows us to keep the distinction between content: none
and content: normal, which allows us to fix the computed style we return from
getComputedStyle().
Do this last bit from the resolved value instead of StyleAdjuster, because
otherwise we need to tweak every initial struct for ::before / ::after.
Differential Revision: https://phabricator.services.mozilla.com/D58276
--HG--
extra : moz-landing-system : lando
In particular, the ones where we transcode unconditionally atm (property names
and such).
There are others like cssText getters and setters which are a bit harder,
because I either need to rewrite all our serialization code to work with UTF8
(which is fine, but a lot of work), or teach webidl to have a setter that takes
UTF8String as input but returns DOMString as output (which is at best hacky).
Differential Revision: https://phabricator.services.mozilla.com/D58631
--HG--
extra : moz-landing-system : lando
This is needed to support min() / max() / clamp(), as LengthPercentage will have
a potential heap allocation and the current copy-assignment operators just do
bitwise copies.
Differential Revision: https://phabricator.services.mozilla.com/D57300
--HG--
extra : moz-landing-system : lando
This includes more bitflag operators, which means we can remove some slightly
ugly code.
Differential Revision: https://phabricator.services.mozilla.com/D56308
--HG--
extra : moz-landing-system : lando
I couldn't get some Windows sandbox code to build with the other patch in this
bug.
Differential Revision: https://phabricator.services.mozilla.com/D56343
--HG--
extra : moz-landing-system : lando
We're vendoring it already so no reason not to. Only a couple dependencies left
after these to get rid of 0.6.
Differential Revision: https://phabricator.services.mozilla.com/D56044
--HG--
extra : moz-landing-system : lando
cbindgen understands references, so use them rather than pointers when we expect
non-null stuff.
Differential Revision: https://phabricator.services.mozilla.com/D55011
--HG--
extra : moz-landing-system : lando
When zoom is disabled, we still count it, but with the current code the testing
function will throw instead of returning the right value, which means we'd fail
layout/style/test/test_use_counters.html.
Differential Revision: https://phabricator.services.mozilla.com/D55005
--HG--
extra : moz-landing-system : lando
This moves the shadow cascade order into the cascade level, and refactors the
code a bit for that.
Differential Revision: https://phabricator.services.mozilla.com/D49988
--HG--
extra : moz-landing-system : lando
The existing code wasn't sound, as CSSOM objects also needed to go away before
the shared memory goes away (as they keep references to them).
This is sound assuming no presence of reference cycles introduced by CSSOM.
We may want to live with this and rely on chrome code not writing cycles like
this with UA stylesheet DOM objects.
We could explicitly drop all potentially-static objects... That seems pretty
error prone though.
Or we could also just leak the shared memory buffer, is there any reason why we
may not want to do that?
Differential Revision: https://phabricator.services.mozilla.com/D51870
--HG--
extra : moz-landing-system : lando
The existing code wasn't sound, as CSSOM objects also needed to go away before
the shared memory goes away (as they keep references to them).
This is sound assuming no presence of reference cycles introduced by CSSOM.
We may want to live with this and rely on chrome code not writing cycles like
this with UA stylesheet DOM objects.
We could explicitly drop all potentially-static objects... That seems pretty
error prone though.
Or we could also just leak the shared memory buffer, is there any reason why we
may not want to do that?
Differential Revision: https://phabricator.services.mozilla.com/D51870
--HG--
extra : moz-landing-system : lando
This also includes the implementation of SetAnimatable, FromAnimatable,
and merge the final matrix with motion path.
Besides, we always use PathBuilderSkia for calculating the gfx::Path for
web-renderer.
Differential Revision: https://phabricator.services.mozilla.com/D50011
--HG--
extra : moz-landing-system : lando
We need to pass these two types into the compositor, so we need a better
way to serialize these rust types. We use serde and bincode to
serialize/deserialize them, and use ByteBuf to pass the &[u8] data
through IPC. We define StyleVecU8 for FFI usage only.
Differential Revision: https://phabricator.services.mozilla.com/D50688
--HG--
extra : moz-landing-system : lando
Adds a feature "moz_xbl" that when disabled causes the XBL code in servo to
be stubbed out.
Depends on D45613
Differential Revision: https://phabricator.services.mozilla.com/D45614
--HG--
extra : moz-landing-system : lando
This fixes another edge-case that I thought of while debugging this, I think
this makes our behavior correct now. The comment and test-case should be
self-descriptive.
Differential Revision: https://phabricator.services.mozilla.com/D48135
--HG--
extra : moz-landing-system : lando
This is a pre-existing bug, and this would be enough to fix the website, but
this is still not 100% correct. More on that in a second.
Differential Revision: https://phabricator.services.mozilla.com/D48134
--HG--
extra : moz-landing-system : lando
C'est fini. Now to do the same with the unimplemented ones remains, but it
should be straight-forward.
Differential Revision: https://phabricator.services.mozilla.com/D44698
--HG--
extra : moz-landing-system : lando
C'est fini. Now to do the same with the unimplemented ones remains, but it
should be straight-forward.
Differential Revision: https://phabricator.services.mozilla.com/D44698
--HG--
extra : moz-landing-system : lando
C'est fini. Now to do the same with the unimplemented ones remains, but it
should be straight-forward.
Differential Revision: https://phabricator.services.mozilla.com/D44698
--HG--
extra : moz-landing-system : lando
C'est fini. Now to do the same with the unimplemented ones remains, but it
should be straight-forward.
Differential Revision: https://phabricator.services.mozilla.com/D44698
--HG--
extra : moz-landing-system : lando
For developing properties, we will handle them in an other bug.
Besides, I use an iframe for the test because we create a use counter in
the constructor of Document, which use the prefs to decide what kind of
properties we want to record. So, in the test, we have to reload iframe
to make sure we re-create the document, so does the use counter, to make
sure the prefs work properly.
The two prefs affect the css use counters:
1. layout.css.use-counters.enabled: Allocate use counters, and record
non-custom properties.
2. layout.css.use-counters-unimplemented.enabled: Record all unimplmented
properties into the use counters.
If we disable layout.css.use-counters.enblaed, we don't create use counters
object, so layout.css.use-counters-unimplemented.enabled doesn't work,
either.
Differential Revision: https://phabricator.services.mozilla.com/D43860
--HG--
extra : moz-landing-system : lando