Merge pull request #784 from arturadib/fix-783
Replacing URL flag format for download
This commit is contained in:
commit
c15311c8eb
@ -52,7 +52,7 @@ pdfContentHandler.prototype = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let targetUrl = aRequest.URI.spec;
|
let targetUrl = aRequest.URI.spec;
|
||||||
if (targetUrl.indexOf('?pdfjs.action=download') >= 0)
|
if (targetUrl.indexOf('#pdfjs.action=download') >= 0)
|
||||||
throw NS_ERROR_WONT_HANDLE_CONTENT;
|
throw NS_ERROR_WONT_HANDLE_CONTENT;
|
||||||
|
|
||||||
aRequest.cancel(Cr.NS_BINDING_ABORTED);
|
aRequest.cancel(Cr.NS_BINDING_ABORTED);
|
||||||
|
@ -139,7 +139,7 @@ var PDFView = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
download: function pdfViewDownload() {
|
download: function pdfViewDownload() {
|
||||||
window.open(this.url + '?pdfjs.action=download', '_parent');
|
window.open(this.url + '#pdfjs.action=download', '_parent');
|
||||||
},
|
},
|
||||||
|
|
||||||
navigateTo: function pdfViewNavigateTo(dest) {
|
navigateTo: function pdfViewNavigateTo(dest) {
|
||||||
|
Loading…
Reference in New Issue
Block a user