Commit Graph

2429 Commits

Author SHA1 Message Date
Andrew Osmond
f56472c614 Bug 1313102 - Fix crash when calculating sizes for VectorImage memory reports. r=tnikkel 2016-10-26 12:46:00 -04:00
Andrew Osmond
fc8ba03399 Bug 1284117 - Make RasterImage and SourceBuffer handle input stream read errors. r=edwin 2016-10-13 10:09:35 -04:00
Andrew Osmond
46250e2a5e Bug 1258741 - Part 2. Ensure we consistently render partially decoded images. r=tnikkel 2016-09-26 14:18:37 -04:00
Andrew Osmond
54d6f7e0c4 Bug 1258741 - Part 1. Remove dead/unused image decoder aborted flag. r=tnikkel 2016-09-21 07:13:08 -04:00
Andrew Osmond
be96e28a0f Bug 1308289 - Hold strong reference to VectorImage when dispatching ProgressTracker::SyncNotifyProgress. r=tnikkel 2016-10-13 08:35:55 -04:00
Ehsan Akhgari
75d4b96af8 Bug 1306800 - Remove support for app theming; r=myk,baku 2016-10-13 13:23:03 -04:00
Tim Huang
aeffcdcbe2 Bug 1277803 - Part 3 : Make the image library uses the correct originAttributes and triggering principal when opening a image channel for favicon loading. r=tnikkel 2016-10-13 15:43:57 +08:00
Cameron McCormack
c1f0ee12ba Bug 1309082 - Part 2: Rename some ImageTracker members. r=bholley
MozReview-Commit-ID: 6yOIKKl8npT

--HG--
extra : rebase_source : 247787a0e18640c878e461c4b600bc36a40bad6d
2016-10-13 15:04:19 +08:00
Cameron McCormack
58c32a9088 Bug 1309082 - Part 1: Extract image tracking from nsDocument into a separate, refcounted object. r=bholley
This is refcounted as we'll need to hold strong references to the ImageTracker
from style structs that load images.

MozReview-Commit-ID: 994gE9tOjAn

--HG--
extra : rebase_source : 2d50059e51b42251c89a92a954cef7b49720ceba
2016-10-13 15:04:15 +08:00
Wes Kocher
2142de26c1 Backed out 8 changesets (bug 1277803) for browser-chrome test failures a=backout
Backed out changeset 477890efdb88 (bug 1277803)
Backed out changeset 49da326bfe68 (bug 1277803)
Backed out changeset 2d17a40a9077 (bug 1277803)
Backed out changeset b1cb0a195ca1 (bug 1277803)
Backed out changeset c7d82459d152 (bug 1277803)
Backed out changeset 3be9a06248af (bug 1277803)
Backed out changeset 8d119ca96999 (bug 1277803)
Backed out changeset be767a6f7ecd (bug 1277803)
2016-10-12 14:26:00 -07:00
Tim Huang
91878c9769 Bug 1277803 - Part 3 : Make the image library uses the correct originAttributes and triggering principal when opening a image channel for favicon loading. r=tnikkel 2016-10-12 17:32:06 +08:00
Nathan Froyd
19607c3802 Bug 1306625 - fix wonky identation in imgFrame.cpp; r=tnikkel
DONTBUILD because whitespace-only fixes are always safe...right?
2016-09-30 23:11:59 -04:00
Andrew Osmond
31ad519348 Bug 1275464 - Part 1. Unregister from handling image memory reports when shutting down. r=njn 2016-09-19 13:29:59 -04:00
James Andreou
a47ce92ac2 Bug 1282124 - Remove nsILoadInfo.usePrivateBrowsing and the SEC_FORCE_PRIVATE_BROWSING flag; r=smaug,jryans 2016-09-27 16:56:44 -04:00
Kate McKinley
c57d400961 Bug 1246540 - HSTS Priming Proof of Concept. r=ckerschb, r=mayhemer, r=jld, r=smaug, r=dkeeler, r=jmaher, p=ally
HSTS priming changes the order of mixed-content blocking and HSTS
upgrades, and adds a priming request to check if a mixed-content load is
accesible over HTTPS and the server supports upgrading via the
Strict-Transport-Security header.

Every call site that uses AsyncOpen2 passes through the mixed-content
blocker, and has a LoadInfo. If the mixed-content blocker marks the load as
needing HSTS priming, nsHttpChannel will build and send an HSTS priming
request on the same URI with the scheme upgraded to HTTPS. If the server
allows the upgrade, then channel performs an internal redirect to the HTTPS URI,
otherwise use the result of mixed-content blocker to allow or block the
load.

nsISiteSecurityService adds an optional boolean out parameter to
determine if the HSTS state is already cached for negative assertions.
If the host has been probed within the previous 24 hours, no HSTS
priming check will be sent.

MozReview-Commit-ID: ES1JruCtDdX

--HG--
extra : rebase_source : 2ac6c93c49f2862fc0b9e595eb0598cd1ea4bedf
2016-09-27 11:27:00 -04:00
Andrew Osmond
1d4866a48f Bug 1120279 - Always check if the next frame is available before advancing an animation. 2016-09-21 12:55:26 -04:00
Andrew Osmond
1286146b81 Bug 1303427 - Continue parsing buffered LZW codes in GIFs even if input stream is complete. r=tn 2016-09-19 09:16:28 -04:00
Manish Goregaokar
fe560e754d Bug 1303920 - Update stylo reftest list; r=heycam
MozReview-Commit-ID: 6fKFLbTL2gW

--HG--
extra : rebase_source : bf87e02799dc530b7d26b2040071ecd8213d36df
2016-09-19 20:20:03 +05:30
Manish Goregaokar
63e75ca24b Bug 1302993 - Mark more expectations for stylo tests, make reftest-stylo green; r=heycam
MozReview-Commit-ID: 9rKqASXgKZH

--HG--
extra : rebase_source : ea4d2cdc5623673827676e52d255c8b6fa34f7dd
2016-09-12 19:18:10 +05:30
Shing Lyu
74414dd285 Bug 1302993 - Update some stylo reftest expectations; r=heycam
MozReview-Commit-ID: 5UUDlAUfBYP

--HG--
extra : rebase_source : c8aff1382e492bc07c59becc697abfb4f7bd8f95
2016-09-12 11:05:21 +05:30
Phil Ringnalda
c58d0d6900 Merge m-i to m-c, a=merge 2016-09-17 13:44:34 -07:00
Phil Ringnalda
ac5e0632ed Backed out changeset c0021d576b3a (bug 1120279) for multiple reftest failures 2016-09-17 09:54:25 -07:00
Andrew Osmond
834a37825b Bug 1120279 - Ensure the animated image state is consistent if redecoding fails or is asynchronous. r=edwin 2016-09-15 15:13:48 -04:00
Nicolas Silva
79bb9f5c0e Bug 1284837 - Disallow implicit conversions from float to integer when creating. r=botond 2016-09-16 17:49:39 +02:00
Bas Schouten
77e2a32f4a Bug 1296657: Attempt to create an mOptSurface of the correct type for the DT we're drawing to. r=tnikkel
MozReview-Commit-ID: 2LIQWUPAuaF
2016-09-15 13:53:12 +02:00
Carsten "Tomcat" Book
0f2c669a48 merge mozilla-inbound to mozilla-central a=merge 2016-09-09 12:02:43 +02:00
Shing Lyu
db11558e50 Bug 1288350 - Temporary reftest list for Stylo vs Gecko test r=heycam,manishearth
--HG--
extra : rebase_source : 4772418bd2813d4e79643a833eb09e47fe893d84
2016-09-05 11:45:39 +08:00
Nicholas Nethercote
3ac8aee67f Bug 1297300 - Add missing checks to GetSpec() calls in image/. r=tnikkel. 2016-08-29 15:34:32 +10:00
Glenn Randers-Pehrson
d0f907ce9b Bug 1297907 - Wrap long lines in nsPNGDecoder.cpp. r=tn
--HG--
extra : rebase_source : 01aba31d91a42a3afe30ea2ddc21118ae779ef79
2016-09-07 09:03:00 -04:00
Michael Layzell
36e08437d0 Bug 1018486 - Part 8: Various other changes, r=smaug
MozReview-Commit-ID: B0dsomkWgEk
2016-09-07 10:50:45 -04:00
Nicholas Nethercote
34dcc7b852 Bug 1299384 - Use MOZ_MUST_USE with NS_warn_if_impl(). r=erahm.
This change avoids lots of false positives for Coverity's CHECKED_RETURN
warning, caused by NS_WARN_IF's current use in both statement-style and
expression-style.

In the case where the code within the NS_WARN_IF has side-effects, I made the
following change.

> NS_WARN_IF(NS_FAILED(FunctionWithSideEffects()));
> -->
> Unused << NS_WARN_IF(NS_FAILED(FunctionWithSideEffects()));

In the case where the code within the NS_WARN_IF lacks side-effects, I made the
following change.

> NS_WARN_IF(!condWithoutSideEffects);
> -->
> NS_WARNING_ASSERTION(condWithoutSideEffects, "msg");

This has two improvements.
- The condition is not evaluated in non-debug builds.
- The sense of the condition is inverted to the familiar "this condition should
  be true" sense used in assertions.

A common variation on the side-effect-free case is the following.

> nsresult rv = Fn();
> NS_WARN_IF_(NS_FAILED(rv));
> -->
> DebugOnly<nsresult rv> = Fn();
> NS_WARNING_ASSERTION(NS_SUCCEEDED(rv), "Fn failed");

--HG--
extra : rebase_source : 58788245021096efa8372a9dc1d597a611d45611
2016-09-02 17:12:24 +10:00
Glenn Randers-Pehrson
7cd996e732 Bug 1295671 - Detect use of system libpng in nsPNGDecoder.cpp. r=tn
--HG--
extra : histedit_source : d6ce06bff319953f2abfa9b3d3acad3386b0a654
2016-08-27 01:23:00 -04:00
cku
5963e84e5a Bug 1190881 - Part 3. mochitest for svg css animation. r=dholbert
MozReview-Commit-ID: JchZk3FrZce

--HG--
extra : rebase_source : 3344b0d77537bf315784a452983b3440c1c385e6
2016-08-25 23:15:04 +08:00
cku
48f9993c70 Bug 1190881 - Part 2. Trigger pending animation for SVG-as-image docs. r=birtles
MozReview-Commit-ID: BOrdKoIDCGX

--HG--
extra : rebase_source : 92f41aae5b9f70e5bfd6760f80302e90d148bd93
2016-08-25 22:58:50 +08:00
cku
4395bfbe1c Bug 1190881 - Part 1. Create and pass a navigation timing object to the wrapped SVG document. r=dholbert
MozReview-Commit-ID: DTtTudlJ52d

--HG--
extra : rebase_source : b0a9c8e79e290f51bf433d0f94b1de7db99e933a
2016-09-02 18:53:36 +08:00
Nicholas Nethercote
742fc7eb48 Bug 1297961 (part 1) - Introduce nsURI::GetSpecOrDefault(). r=hurley.
This function is an infallible alternative to nsIURI::GetSpec(). It's useful
when it's appropriate to handle a GetSpec() failure with a failure string, e.g.
for log/warning/error messages. It allows code like this:

  nsAutoCString spec;
  uri->GetSpec(spec);
  printf("uri: %s", spec.get());

to be changed to this:

  printf("uri: %s", uri->GetSpecOrDefault().get());

This introduces a slight behavioural change. Previously, if GetSpec() failed,
an empty string would be used here. Now, "[nsIURI::GetSpec failed]" will be
produced instead. In most cases this failure string will make for a clearer
log/warning/error message than the empty string.
* * *
Bug 1297961 (part 1b) - More GetSpecOrDefault() additions. r=hurley.

I will fold this into part 1 before landing.

--HG--
extra : rebase_source : ddc19a5624354ac098be019ca13cc24b99b80ddc
2016-08-26 16:02:31 +10:00
Nicholas Nethercote
819433bae0 Bug 1299389 - Replace some raw pointers in nsThreadManager. r=froydnj.
nsThreadManager::get() can return a reference. This lets us remove some
redundant assertions.

nsThreadArray elements can be NotNull<>s.

--HG--
extra : rebase_source : fd49010167101bc15f7f6d01bf95fd63b81d60fb
2016-06-10 16:04:49 +10:00
Benjamin Smedberg
d5f9ba36f4 Bug 1299545 - stop exporting imgLoader::SupportImageWithMimeType, r=tnikkel
MozReview-Commit-ID: CFmUXAGeFIO

--HG--
extra : rebase_source : 9008a537fce0d2d649a00b04b07e9873024edafc
2016-08-30 13:28:16 -04:00
Lee Salzman
642347dba7 Bug 725119 - fuzz for reftests with Skia content on Android. r=mchang
MozReview-Commit-ID: 9p8ntO7YLQ4
2016-08-31 15:53:33 -04:00
Seth Fowler
a5b5245612 Bug 1298551 - Respect CachedSurface::SetLocked() even if the underlying ISurfaceProvider is always locked. r=dholbert 2016-08-26 17:03:25 -07:00
Seth Fowler
f8818933fa Bug 1296828 (Part 3) - Update SurfaceCache API to rely on ImageKeys and SurfaceKeys stored on ISurfaceProviders. r=dholbert 2016-08-26 17:03:19 -07:00
Seth Fowler
f9e85bafb2 Bug 1296828 (Part 2) - Store ImageKeys and SurfaceKeys directly on ISurfaceProviders. r=dholbert,edwin 2016-08-26 17:03:17 -07:00
Seth Fowler
8f4ebfcf90 Bug 1296828 (Part 1) - Use ImageKey consistently in SurfaceCache. r=dholbert 2016-08-26 17:03:15 -07:00
Mason Chang
43e77092c9 Bug 1007702. Enable skia on unaccelerated windows. r=lsalzman 2016-08-25 12:35:41 -07:00
Seth Fowler
fd83d4ee88 Bug 1296762 (Part 3) - Use NotNull for all CachedSurfaces in SurfaceCache. r=dholbert 2016-08-25 11:42:00 -07:00
Seth Fowler
6006fb4945 Bug 1296762 (Part 2) - Forbid null ISurfaceProviders in SurfaceCache. r=dholbert 2016-08-25 11:41:58 -07:00
Seth Fowler
dda03690ef Bug 1296762 (Part 1) - Remove SurfaceCache::InsertPlaceholder(). r=dholbert 2016-08-25 11:41:57 -07:00
Nicholas Nethercote
c2306345d5 Bug 1297658 - Avoid unnecessary checking in memory reporters. r=erahm.
This patch removes checking of all the callback calls in memory reporter
CollectReport() functions, because it's not useful.

The patch also does some associated clean-up.

- Replaces some uses of nsIMemoryReporterCallback with the preferred
  nsIHandleReportCallback typedef.

- Replaces aCallback/aCb/aClosure with aHandleRepor/aData for CollectReports()
  parameter names, for consistency.

- Adds MOZ_MUST_USE/[must_use] in a few places in nsIMemoryReporter.idl.

- Uses the MOZ_COLLECT_REPORT macro in all suitable places.

Overall the patch reduces code size by ~300 lines and reduces the size of
libxul by about 37 KiB on my Linux64 builds.

--HG--
extra : rebase_source : e94323614bd10463a0c5134a7276238a7ca1cf23
2016-08-24 15:23:45 +10:00
Kan-Ru Chen
b6d880aca1 Bug 1297276 - Rename mfbt/unused.h to mfbt/Unused.h for consistency. r=froydnj
The patch is generated from following command:

  rgrep -l unused.h|xargs sed -i -e s,mozilla/unused.h,mozilla/Unused.h,

MozReview-Commit-ID: AtLcWApZfES


--HG--
rename : mfbt/unused.h => mfbt/Unused.h
2016-08-24 14:47:04 +08:00
Timothy Nikkel
05dc5b9ede Bug 1260324. Don't draw garbage to the screen if an image doesn't happen to be decoded. r=seth
Layout has been using imgIContainer::IsOpaque to determine if the image will draw opaquely to all pixels it covers, and doing culling based on this.

However imgIContainer::IsOpaque doesn't guarantee anything. It only describes if the image, when in a decoded state, has all opaque pixels. So if the image doesn't have fully decoded frames around (because they got discarded) it may not draw opaquely to all of its pixels.

So we create a new function that first checks if there is a fully decoded frame.
2016-08-22 21:15:38 -05:00