summaryrefslogtreecommitdiffstats
path: root/chromium/chrome/browser/resources/print_preview/data/document_info.js
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/chrome/browser/resources/print_preview/data/document_info.js')
-rw-r--r--chromium/chrome/browser/resources/print_preview/data/document_info.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/chromium/chrome/browser/resources/print_preview/data/document_info.js b/chromium/chrome/browser/resources/print_preview/data/document_info.js
index 67ce1c952af..d85124d3a13 100644
--- a/chromium/chrome/browser/resources/print_preview/data/document_info.js
+++ b/chromium/chrome/browser/resources/print_preview/data/document_info.js
@@ -9,6 +9,7 @@ cr.exportPath('print_preview');
* hasCssMediaStyles: boolean,
* hasSelection: boolean,
* isModifiable: boolean,
+ * isPdf: boolean,
* isScalingDisabled: boolean,
* fitToPageScaling: number,
* pageCount: number,
@@ -48,6 +49,7 @@ Polymer({
hasCssMediaStyles: false,
hasSelection: false,
isModifiable: true,
+ isPdf: false,
isScalingDisabled: false,
fitToPageScaling: 100,
pageCount: 0,
@@ -113,13 +115,16 @@ Polymer({
/**
* Initializes the state of the data model.
* @param {boolean} isModifiable Whether the document is modifiable.
+ * @param {boolean} isPdf Whether the document is PDF.
* @param {string} title Title of the document.
* @param {boolean} hasSelection Whether the document has user-selected
* content.
*/
- init: function(isModifiable, title, hasSelection) {
+ init: function(isModifiable, isPdf, title, hasSelection) {
this.isInitialized_ = true;
this.set('documentSettings.isModifiable', isModifiable);
+ // TODO(crbug.com/702995): Remove once Flash is deprecated.
+ this.set('documentSettings.isPdf', isPdf);
this.set('documentSettings.title', title);
this.set('documentSettings.hasSelection', hasSelection);
},
@@ -154,7 +159,7 @@ Polymer({
Math.round(pageLayout.marginTop), Math.round(pageLayout.marginRight),
Math.round(pageLayout.marginBottom), Math.round(pageLayout.marginLeft));
- const o = print_preview.ticket_items.CustomMarginsOrientation;
+ const o = print_preview.CustomMarginsOrientation;
const pageSize = new print_preview.Size(
pageLayout.contentWidth + margins.get(o.LEFT) + margins.get(o.RIGHT),
pageLayout.contentHeight + margins.get(o.TOP) + margins.get(o.BOTTOM));