mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-25 17:48:07 +02:00
Hack to support automatic printing from pdf javascript.
This commit is contained in:
parent
e20a9846ca
commit
5c43565404
4 changed files with 120 additions and 23 deletions
10
src/api.js
10
src/api.js
|
@ -119,6 +119,16 @@ var PDFDocumentProxy = (function PDFDocumentProxyClosure() {
|
|||
promise.resolve(destinations);
|
||||
return promise;
|
||||
},
|
||||
/**
|
||||
* @return {Promise} A promise that is resolved with an array of all the
|
||||
* JavaScript strings in the name tree.
|
||||
*/
|
||||
getJavaScript: function PDFDocumentProxy_getDestinations() {
|
||||
var promise = new PDFJS.Promise();
|
||||
var js = this.pdfInfo.javaScript;
|
||||
promise.resolve(js);
|
||||
return promise;
|
||||
},
|
||||
/**
|
||||
* @return {Promise} A promise that is resolved with an {array} that is a
|
||||
* tree outline (if it has one) of the PDF. The tree is in the format of:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue