1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-26 01:58:06 +02:00

Removes global PDFJS usage from the src/core/.

This commit is contained in:
Yury Delendik 2016-03-02 18:48:21 -06:00
parent 21ed8ff71d
commit bda5e6235e
22 changed files with 376 additions and 299 deletions

View file

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* globals PDFJS */
'use strict';
@ -36,6 +35,7 @@ var Util = sharedUtil.Util;
var error = sharedUtil.error;
var info = sharedUtil.info;
var isArray = sharedUtil.isArray;
var createObjectURL = sharedUtil.createObjectURL;
var shadow = sharedUtil.shadow;
var warn = sharedUtil.warn;
var Dict = corePrimitives.Dict;
@ -963,8 +963,8 @@ var JpegStream = (function JpegStreamClosure() {
return this.buffer;
};
JpegStream.prototype.getIR = function JpegStream_getIR() {
return PDFJS.createObjectURL(this.bytes, 'image/jpeg');
JpegStream.prototype.getIR = function JpegStream_getIR(forceDataSchema) {
return createObjectURL(this.bytes, 'image/jpeg', forceDataSchema);
};
/**
* Checks if the image can be decoded and displayed by the browser without any