Commit Graph

18 Commits

Author SHA1 Message Date
Dave Townsend
e7b1b3284f Bug 1316882: Turn on space-before-function-paren eslint rule (toolkit). r=jaws
MozReview-Commit-ID: FGFwg6TYkvm
2016-11-11 15:22:34 -08:00
Oliver Henshaw
f3ae4d2011 Bug 1192394 - Force an image load whenever the thumbnail file changes. r=adw
Add a revision tag to moz-page-thumb URLs. Change it whenever a new
thumbnail is captured and stored to disk. This prevents new loads from
re-using the old cached value even if the document context matches the
stored loadId of the cache entry.

Also drop no-longer needed wait in browser_thumbnails_update.js test.

Restores behaviour of test/head.js:retrieveImageDataForURL to that of
before bug 897880 - i.e. load the thumbnail image in the context of the
top level chrome document (rather than a new tab every time). It's
likely that bug 1192394 is the reason for the test failures observed in
bug 897880 comment #11.
2015-10-29 16:03:00 +01:00
Oliver Henshaw
be94614774 Bug 1180715 (3/4) - Drop parseURI from newChannel2. review=ttaubert
Extract the nsIFile from aURI instead.
2015-10-20 10:45:46 +05:30
Oliver Henshaw
7b85ab126c Bug 1180715 (4/4) - Use nsIURL methods instead of RegExp. review=ttaubert
Also move host check from the parseURI caller to parseURI itself.
2015-10-20 10:45:40 +05:30
Oliver Henshaw
d871d11e13 Bug 1180715 (2/4) - Provide a nsIFileURL interface for thumbnails. review=ttaubert
Use nsISubstitutingProtocolHandler to return a SubstitutingURL and to
resolve the thumbnail URL to the backing nsIFile.

Now the image loader code will realise that moz-page-thumb:// URLs are
backed by a file and will be able to use the file mtime to evaluate
whether the cached imgRequest has expired.

* Implement the nsISubstitutingProtocolHandler methods in the thumbnail
protocol handler. The resolveURI method does all the work, the other
methods are just stubs.

* moz-page-thumb:// is now an URL rather than an URI, so update the
signature accordingly.

* Add xpcshell-test to affirm that SubstitutingURL::EnsureFile()
resolves the backing file correctly.

* Adjust the mochitest to account for the one second granularity of the
mtime tracking.
2015-10-20 10:45:32 +05:30
Tooru Fujisawa
afbd2956bc Bug 1207498 - Part 1: Remove use of expression closure from toolkit/components/, except tests. r=Gijs 2015-09-24 20:32:23 +09:00
Tooru Fujisawa
3d13712ac2 Backed out changeset 036615ba3257 (bug 1207498) for Linux pgo M(oth) failure 2015-09-27 23:42:50 +09:00
Tooru Fujisawa
f2efd2a948 Bug 1207498 - Part 1: Remove use of expression closure from toolkit/components/, except tests. r=Gijs 2015-09-24 20:32:23 +09:00
Christoph Kerschbaumer
6e5fcd4b19 Bug 1180273 - Adding missing 'this' pointer when forwarding newChannel2 calls (r=gijs,sicking) 2015-08-06 11:11:32 -07:00
Carsten "Tomcat" Book
24bab71afa Backed out 2 changesets (bug 1191107, bug 1180273) for causing xpcshell and m-oth testfailures on a CLOSED TREEi IGNORE IDL
Backed out changeset c5f710ed8718 (bug 1191107)
Backed out changeset d98d82f9981b (bug 1180273)
2015-08-06 08:39:05 +02:00
Christoph Kerschbaumer
65acc2a8ec Bug 1180273 - Adding missing 'this' pointer when forwarding newChannel2 calls (r=gijs,sicking) 2015-08-05 12:55:14 -07:00
Seth Fowler
375f6d817b Bug 1163866 - Set originalURI correctly for moz-page-thumb:// channels. r=adw 2015-05-12 18:45:49 -07:00
Christoph Kerschbaumer
e57b36cb13 Bug 1147562 - Update remaining callsites of newChannel before landing the shim in toolkit/ (r=gijs) 2015-04-09 10:10:45 -07:00
Christoph Kerschbaumer
2bb13c0b9b Bug 1087744: Make JS callers of ios.newChannel call ios.newChannel2 in toolkit/ (r=gijs) 2014-10-24 15:25:34 -07:00
Tim Taubert
122a932853 Bug 1046645 - Revert part of the first patch and remove URI_IS_LOCAL_FILE from PageThumbsProtocolHandler again 2014-09-02 12:23:39 -04:00
Tim Taubert
fca07c7e6e Bug 1046645 - Mark moz-page-thumb:// as local resources to prevent mixed content warnings f=Mardak r=gavin
Mixed content warnings on valid https pages may sometimes occur when a thumbnail on about:newtab is refreshed while we're already transitioning to the new web page. The "insecure" request is counted as a subresource request towards the newly started load. If the new target is a https page this may result in a mixed content warning because nsSecureBrowserUI is dumb and can't tell the requests of the current and previous page loads apart.
2014-08-28 11:26:35 +02:00
David Rajchenbach-Teller
65b411a8fe Bug 753768 - Moving Page Thumbs I/O fully off the main thread;r=ttaubert 2013-03-27 16:35:56 +01:00
Matt Brubeck
6ddb8e6f39 Bug 811548 - Move PageThumbs.jsm from /browser to /toolkit 2013-02-16 20:15:41 -08:00