Index: chrome/browser/resources/pdf/pdf.js |
diff --git a/chrome/browser/resources/pdf/pdf.js b/chrome/browser/resources/pdf/pdf.js |
index c7b172078d7778472af64c4fe851a35bca15b73e..a71af583285105c945178858641a53f0937fdd38 100644 |
--- a/chrome/browser/resources/pdf/pdf.js |
+++ b/chrome/browser/resources/pdf/pdf.js |
@@ -202,8 +202,12 @@ function PDFViewer(browserApi) { |
this.plugin_.setAttribute('background-color', backgroundColor); |
this.plugin_.setAttribute('top-toolbar-height', topToolbarHeight); |
- if (!this.browserApi_.getStreamInfo().embedded) |
+ if (this.browserApi_.getStreamInfo().embedded) { |
+ this.plugin_.setAttribute('embedder-url', |
raymes
2016/09/05 04:11:47
I think top-level-url may be more accurate here (t
Lei Zhang
2016/09/07 00:12:39
Done in all the places.
|
+ this.browserApi_.getStreamInfo().tabUrl); |
+ } else { |
this.plugin_.setAttribute('full-frame', ''); |
raymes
2016/09/05 04:11:47
optional: We could merge this with top-level-url a
Lei Zhang
2016/09/07 00:12:38
Can we ever be embedded, but have an empty top-lev
|
+ } |
document.body.appendChild(this.plugin_); |
// Setup the button event listeners. |