Commit ceb9d4b2 authored by csillag's avatar csillag

Update PDF plugin

... to cfac672e (typed-packaging branch).

Fixes #1788.
parent 17bc4593
// Generated by CoffeeScript 1.6.3 // Generated by CoffeeScript 1.6.3
/* /*
** Annotator 1.2.6-dev-6623b2c ** Annotator 1.2.6-dev-bee2b25
** https://github.com/okfn/annotator/ ** https://github.com/okfn/annotator/
** **
** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning. ** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning.
** Dual licensed under the MIT and GPLv3 licenses. ** Dual licensed under the MIT and GPLv3 licenses.
** https://github.com/okfn/annotator/blob/master/LICENSE ** https://github.com/okfn/annotator/blob/master/LICENSE
** **
** Built at: 2014-12-11 01:33:35Z ** Built at: 2014-12-11 02:43:05Z
*/ */
...@@ -124,9 +124,7 @@ ...@@ -124,9 +124,7 @@
} }
} }
}); });
return $(this._viewer.container).on('scroll', function() { return this._viewer.container.addEventListener("scroll", this._onScroll);
return _this._onScroll();
});
}; };
PDFTextMapper.prototype._extractionPattern = /[ ]+/g; PDFTextMapper.prototype._extractionPattern = /[ ]+/g;
...@@ -217,7 +215,7 @@ ...@@ -217,7 +215,7 @@
}; };
PDFTextMapper.prototype.getDocumentInfo = function() { PDFTextMapper.prototype.getDocumentInfo = function() {
return this.app.documentInfo; return this._app.documentInfo;
}; };
return PDFTextMapper; return PDFTextMapper;
...@@ -314,7 +312,13 @@ ...@@ -314,7 +312,13 @@
return new Promise(function(resolve, reject) { return new Promise(function(resolve, reject) {
if (_this.annotator.domMapper.waitForInit != null) { if (_this.annotator.domMapper.waitForInit != null) {
return _this.annotator.domMapper.waitForInit().then(function() { return _this.annotator.domMapper.waitForInit().then(function() {
var error;
try {
return resolve(_this._metadata()); return resolve(_this._metadata());
} catch (_error) {
error = _error;
return reject("Internal error");
}
}); });
} else { } else {
return reject("Not a PDF dom mapper."); return reject("Not a PDF dom mapper.");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment