Browse Source

PDF.js version 1.5.458 - See mozilla/pdf.js@a7c35025fed8beb8f9b93688fff40497c7ad2de0

master v1.5.458
Pdf Bot 8 years ago
parent
commit
e64086ccf3
  1. 2
      bower.json
  2. 24
      build/pdf.combined.js
  3. 9
      build/pdf.js
  4. 19
      build/pdf.worker.js
  5. 2
      package.json

2
bower.json

@ -1,6 +1,6 @@ @@ -1,6 +1,6 @@
{
"name": "pdfjs-dist",
"version": "1.5.456",
"version": "1.5.458",
"main": [
"build/pdf.js",
"build/pdf.worker.js"

24
build/pdf.combined.js

@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdfCombined = {})); @@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdfCombined = {}));
// Use strict in our context only - users might not want it
'use strict';
var pdfjsVersion = '1.5.456';
var pdfjsBuild = '4d15928';
var pdfjsVersion = '1.5.458';
var pdfjsBuild = 'a7c3502';
var pdfjsFilePath =
typeof document !== 'undefined' && document.currentScript ?
@ -24130,7 +24130,6 @@ exports.LZWStream = LZWStream; @@ -24130,7 +24130,6 @@ exports.LZWStream = LZWStream;
var AnnotationBorderStyleType = sharedUtil.AnnotationBorderStyleType;
var AnnotationType = sharedUtil.AnnotationType;
var isInt = sharedUtil.isInt;
var Util = sharedUtil.Util;
var addLinkAttributes = displayDOMUtils.addLinkAttributes;
var LinkTarget = displayDOMUtils.LinkTarget;
@ -24552,7 +24551,7 @@ var TextWidgetAnnotationElement = ( @@ -24552,7 +24551,7 @@ var TextWidgetAnnotationElement = (
element.type = 'text';
element.value = this.data.fieldValue;
if (isInt(this.data.maxLen)) {
if (this.data.maxLen !== null) {
element.maxLength = this.data.maxLen;
}
} else {
@ -24568,7 +24567,7 @@ var TextWidgetAnnotationElement = ( @@ -24568,7 +24567,7 @@ var TextWidgetAnnotationElement = (
this._setTextStyle(element, font);
}
if (isInt(this.data.textAlignment)) {
if (this.data.textAlignment !== null) {
element.style.textAlign = TEXT_ALIGNMENT[this.data.textAlignment];
}
@ -49656,8 +49655,19 @@ var TextWidgetAnnotation = (function TextWidgetAnnotationClosure() { @@ -49656,8 +49655,19 @@ var TextWidgetAnnotation = (function TextWidgetAnnotationClosure() {
function TextWidgetAnnotation(params) {
WidgetAnnotation.call(this, params);
this.data.textAlignment = Util.getInheritableProperty(params.dict, 'Q');
this.data.maxLen = Util.getInheritableProperty(params.dict, 'MaxLen');
// Determine the alignment of text in the field.
var alignment = Util.getInheritableProperty(params.dict, 'Q');
if (!isInt(alignment) || alignment < 0 || alignment > 2) {
alignment = null;
}
this.data.textAlignment = alignment;
// Determine the maximum length of text in the field.
var maximumLength = Util.getInheritableProperty(params.dict, 'MaxLen');
if (!isInt(maximumLength) || maximumLength < 0) {
maximumLength = null;
}
this.data.maxLen = maximumLength;
}
Util.inherit(TextWidgetAnnotation, WidgetAnnotation, {

9
build/pdf.js

@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdf = {})); @@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdf = {}));
// Use strict in our context only - users might not want it
'use strict';
var pdfjsVersion = '1.5.456';
var pdfjsBuild = '4d15928';
var pdfjsVersion = '1.5.458';
var pdfjsBuild = 'a7c3502';
var pdfjsFilePath =
typeof document !== 'undefined' && document.currentScript ?
@ -4325,7 +4325,6 @@ exports.SVGGraphics = SVGGraphics; @@ -4325,7 +4325,6 @@ exports.SVGGraphics = SVGGraphics;
var AnnotationBorderStyleType = sharedUtil.AnnotationBorderStyleType;
var AnnotationType = sharedUtil.AnnotationType;
var isInt = sharedUtil.isInt;
var Util = sharedUtil.Util;
var addLinkAttributes = displayDOMUtils.addLinkAttributes;
var LinkTarget = displayDOMUtils.LinkTarget;
@ -4747,7 +4746,7 @@ var TextWidgetAnnotationElement = ( @@ -4747,7 +4746,7 @@ var TextWidgetAnnotationElement = (
element.type = 'text';
element.value = this.data.fieldValue;
if (isInt(this.data.maxLen)) {
if (this.data.maxLen !== null) {
element.maxLength = this.data.maxLen;
}
} else {
@ -4763,7 +4762,7 @@ var TextWidgetAnnotationElement = ( @@ -4763,7 +4762,7 @@ var TextWidgetAnnotationElement = (
this._setTextStyle(element, font);
}
if (isInt(this.data.textAlignment)) {
if (this.data.textAlignment !== null) {
element.style.textAlign = TEXT_ALIGNMENT[this.data.textAlignment];
}

19
build/pdf.worker.js vendored

@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdfWorker = {})); @@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdfWorker = {}));
// Use strict in our context only - users might not want it
'use strict';
var pdfjsVersion = '1.5.456';
var pdfjsBuild = '4d15928';
var pdfjsVersion = '1.5.458';
var pdfjsBuild = 'a7c3502';
var pdfjsFilePath =
typeof document !== 'undefined' && document.currentScript ?
@ -40800,8 +40800,19 @@ var TextWidgetAnnotation = (function TextWidgetAnnotationClosure() { @@ -40800,8 +40800,19 @@ var TextWidgetAnnotation = (function TextWidgetAnnotationClosure() {
function TextWidgetAnnotation(params) {
WidgetAnnotation.call(this, params);
this.data.textAlignment = Util.getInheritableProperty(params.dict, 'Q');
this.data.maxLen = Util.getInheritableProperty(params.dict, 'MaxLen');
// Determine the alignment of text in the field.
var alignment = Util.getInheritableProperty(params.dict, 'Q');
if (!isInt(alignment) || alignment < 0 || alignment > 2) {
alignment = null;
}
this.data.textAlignment = alignment;
// Determine the maximum length of text in the field.
var maximumLength = Util.getInheritableProperty(params.dict, 'MaxLen');
if (!isInt(maximumLength) || maximumLength < 0) {
maximumLength = null;
}
this.data.maxLen = maximumLength;
}
Util.inherit(TextWidgetAnnotation, WidgetAnnotation, {

2
package.json

@ -1,6 +1,6 @@ @@ -1,6 +1,6 @@
{
"name": "pdfjs-dist",
"version": "1.5.456",
"version": "1.5.458",
"main": "build/pdf.js",
"description": "Generic build of Mozilla's PDF.js library.",
"keywords": [

Loading…
Cancel
Save