GetStyleContext can flush. As such, that flush can kill the pres shell, and the
return value could be null. I have no idea why that code was asserting it didn't
happen, but that assert is completely bogus.
Throw instead, just like GetFontParentStyleContext used to do for Gecko.
MozReview-Commit-ID: 5RxDratKumZ
--HG--
extra : rebase_source : 9ffb1f58888504d92915ecd4254847ae2e3f053b
The canvas prompt is extremely annoying. It happens everyone, automatically. And in
99.9% (not scientific) of cases it is not triggered by user input, but my automatic
tracking scripts.
This commit will automatically decline the canvas read if it was not triggered by
user input.
Just in case this breaks something irrepairably, we have a cutoff pref.
We don't intend to keep this pref forever, and have asked anyone who sets it to
tell us why.
MozReview-Commit-ID: CxNkuraRWpV
--HG--
extra : rebase_source : 12cfc94cecbd378c0859ae50066c6338bcaa6692
The only relevant spec reference unfortunately is for color parsing[1], which
mentions:
> Otherwise, set color to the computed value of the 'color' property of element.
Using IsInComposedDoc there should be fine, since the computed style of an
element is well defined there.
The rest look like implementation limitations, for which should not be an issue
to extend the check for the composed doc.
[1]: https://html.spec.whatwg.org/#parsed-as-a-css-color-value
MozReview-Commit-ID: ADnVPNqf3X1
--HG--
extra : rebase_source : ea72f695afe86820d2d04c2b8eca1d17bc356a71
Everyone calls them with the shell of the current composed document, and this
allows the multi-presShell stuff to just be in UpdateCurrentStyleSources /
DoGetStyleContextNoFlush.
The only reason we need to use OwnerDoc()->GetShell() instead of the composed
doc in GetStyleContext / GetStyleContextNoFlush is Element::GetBindingURL, which
does expect to get the binding URL for stuff outside of the composed doc (and
changing that gave me a useless browser).
That's technically a behavior change on the cases that used to pass nullptr, but
I think all callers are fine with that. I could also just add a special function
for that particular case, it may be worth it.
MozReview-Commit-ID: 2XlnkgdgDCK
And remove the two cases that currently set that, without actually using
it. The webrtc gtest one never relied on it, and the gfx one was added
in bug 1427668 for a single header, and the corresponding #includes were
changed in bug 1428678.
--HG--
extra : rebase_source : ebb3aed6ff8e3438d4a2f011725cf1a15986fee6
Remove the probe, and remove the cached value check.
Also remove dead code which relies on this sometimes-clamping glGet query.
MozReview-Commit-ID: JA1VgH8fLRB
And trigger a new Ubuntu 16.04 docker image with a different hash to get
the latest version of the GL drivers that were updated to llvmpipe 5
recently. Those new drivers make Firefox enabled
WEBGL_compressed_texture_s3tc, making the test pass.
--HG--
extra : rebase_source : 09a8995829f985aef29a8919fecaefaf90791584