|
@@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdf = {}));
|
|
|
// Use strict in our context only - users might not want it
|
|
|
'use strict';
|
|
|
|
|
|
-var pdfjsVersion = '1.4.23';
|
|
|
-var pdfjsBuild = '252b9d5';
|
|
|
+var pdfjsVersion = '1.4.31';
|
|
|
+var pdfjsBuild = '825a222';
|
|
|
|
|
|
var pdfjsFilePath =
|
|
|
typeof document !== 'undefined' && document.currentScript ?
|
|
@@ -94,7 +94,7 @@ var CustomStyle = (function CustomStyleClosure() {
|
|
|
// in some versions of IE9 it is critical that ms appear in this list
|
|
|
// before Moz
|
|
|
var prefixes = ['ms', 'Moz', 'Webkit', 'O'];
|
|
|
- var _cache = {};
|
|
|
+ var _cache = Object.create(null);
|
|
|
|
|
|
function CustomStyle() {}
|
|
|
|
|
@@ -485,6 +485,18 @@ function shadow(obj, prop, value) {
|
|
|
}
|
|
|
PDFJS.shadow = shadow;
|
|
|
|
|
|
+function getLookupTableFactory(initializer) {
|
|
|
+ var lookup;
|
|
|
+ return function () {
|
|
|
+ if (initializer) {
|
|
|
+ lookup = Object.create(null);
|
|
|
+ initializer(lookup);
|
|
|
+ initializer = null;
|
|
|
+ }
|
|
|
+ return lookup;
|
|
|
+ };
|
|
|
+}
|
|
|
+
|
|
|
var LinkTarget = PDFJS.LinkTarget = {
|
|
|
NONE: 0, // Default value.
|
|
|
SELF: 1,
|
|
@@ -1582,7 +1594,7 @@ var StatTimer = (function StatTimerClosure() {
|
|
|
return str;
|
|
|
}
|
|
|
function StatTimer() {
|
|
|
- this.started = {};
|
|
|
+ this.started = Object.create(null);
|
|
|
this.times = [];
|
|
|
this.enabled = true;
|
|
|
}
|
|
@@ -1676,8 +1688,8 @@ function MessageHandler(sourceName, targetName, comObj) {
|
|
|
this.comObj = comObj;
|
|
|
this.callbackIndex = 1;
|
|
|
this.postMessageTransfers = true;
|
|
|
- var callbacksCapabilities = this.callbacksCapabilities = {};
|
|
|
- var ah = this.actionHandler = {};
|
|
|
+ var callbacksCapabilities = this.callbacksCapabilities = Object.create(null);
|
|
|
+ var ah = this.actionHandler = Object.create(null);
|
|
|
|
|
|
this._onComObjOnMessage = function messageHandlerComObjOnMessage(event) {
|
|
|
var data = event.data;
|
|
@@ -2466,6 +2478,7 @@ exports.combineUrl = combineUrl;
|
|
|
exports.createPromiseCapability = createPromiseCapability;
|
|
|
exports.deprecated = deprecated;
|
|
|
exports.error = error;
|
|
|
+exports.getLookupTableFactory = getLookupTableFactory;
|
|
|
exports.info = info;
|
|
|
exports.isArray = isArray;
|
|
|
exports.isArrayBuffer = isArrayBuffer;
|
|
@@ -3542,7 +3555,7 @@ Object.defineProperty(FontLoader, 'isSyncFontLoadingSupported', {
|
|
|
|
|
|
var FontFaceObject = (function FontFaceObjectClosure() {
|
|
|
function FontFaceObject(translatedData) {
|
|
|
- this.compiledGlyphs = {};
|
|
|
+ this.compiledGlyphs = Object.create(null);
|
|
|
// importing translated data
|
|
|
for (var i in translatedData) {
|
|
|
this[i] = translatedData[i];
|
|
@@ -3696,7 +3709,7 @@ var Metadata = PDFJS.Metadata = (function MetadataClosure() {
|
|
|
}
|
|
|
|
|
|
this.metaDocument = meta;
|
|
|
- this.metadata = {};
|
|
|
+ this.metadata = Object.create(null);
|
|
|
this.parse();
|
|
|
}
|
|
|
|
|
@@ -4114,7 +4127,7 @@ var SVGGraphics = (function SVGGraphicsClosure() {
|
|
|
this.pendingEOFill = false;
|
|
|
|
|
|
this.embedFonts = false;
|
|
|
- this.embeddedFonts = {};
|
|
|
+ this.embeddedFonts = Object.create(null);
|
|
|
this.cssStyle = null;
|
|
|
}
|
|
|
|
|
@@ -9106,7 +9119,7 @@ var PDFPageProxy = (function PDFPageProxyClosure() {
|
|
|
this.objs = new PDFObjects();
|
|
|
this.cleanupAfterRender = false;
|
|
|
this.pendingCleanup = false;
|
|
|
- this.intentStates = {};
|
|
|
+ this.intentStates = Object.create(null);
|
|
|
this.destroyed = false;
|
|
|
}
|
|
|
PDFPageProxy.prototype = /** @lends PDFPageProxy.prototype */ {
|
|
@@ -9181,7 +9194,7 @@ var PDFPageProxy = (function PDFPageProxyClosure() {
|
|
|
var renderingIntent = (params.intent === 'print' ? 'print' : 'display');
|
|
|
|
|
|
if (!this.intentStates[renderingIntent]) {
|
|
|
- this.intentStates[renderingIntent] = {};
|
|
|
+ this.intentStates[renderingIntent] = Object.create(null);
|
|
|
}
|
|
|
var intentState = this.intentStates[renderingIntent];
|
|
|
|
|
@@ -9273,7 +9286,7 @@ var PDFPageProxy = (function PDFPageProxyClosure() {
|
|
|
|
|
|
var renderingIntent = 'oplist';
|
|
|
if (!this.intentStates[renderingIntent]) {
|
|
|
- this.intentStates[renderingIntent] = {};
|
|
|
+ this.intentStates[renderingIntent] = Object.create(null);
|
|
|
}
|
|
|
var intentState = this.intentStates[renderingIntent];
|
|
|
|
|
@@ -10088,7 +10101,7 @@ var WorkerTransport = (function WorkerTransportClosure() {
|
|
|
*/
|
|
|
var PDFObjects = (function PDFObjectsClosure() {
|
|
|
function PDFObjects() {
|
|
|
- this.objs = {};
|
|
|
+ this.objs = Object.create(null);
|
|
|
}
|
|
|
|
|
|
PDFObjects.prototype = {
|
|
@@ -10179,7 +10192,7 @@ var PDFObjects = (function PDFObjectsClosure() {
|
|
|
},
|
|
|
|
|
|
clear: function PDFObjects_clear() {
|
|
|
- this.objs = {};
|
|
|
+ this.objs = Object.create(null);
|
|
|
}
|
|
|
};
|
|
|
return PDFObjects;
|