diff options
author | Daniel Calviño Sánchez <danxuliu@gmail.com> | 2018-02-24 15:15:03 +0300 |
---|---|---|
committer | Daniel Calviño Sánchez <danxuliu@gmail.com> | 2018-03-09 14:11:20 +0300 |
commit | 405bd52f035ca3bb8133b6f8428ca38fe2ec5f98 (patch) | |
tree | 9483f27d18d4ff1cd242436e800e976ac374e259 | |
parent | b5f94c67e86ad11bf82be977fb611f6b56153eb2 (diff) |
Enable full screen mode for PDF files
The PDF viewer provides a "Full screen" button when it detects that the
browser supports the full screen mode and that the PDF is inside an
element that can be displayed full screen. Therefore, as the PDF viewer
is shown inside an "iframe" element its "allowfullscreen" attribute must
be set to "true".
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
-rw-r--r-- | js/previewplugin.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/previewplugin.js b/js/previewplugin.js index 80afafb..1a9794e 100644 --- a/js/previewplugin.js +++ b/js/previewplugin.js @@ -47,7 +47,7 @@ var shown = true; var $iframe; var viewer = OC.generateUrl('/apps/files_pdfviewer/?file={file}', {file: downloadUrl}); - $iframe = $('<iframe id="pdframe" style="width:100%;height:100%;display:block;position:absolute;top:0;z-index:1041;" src="'+viewer+'" sandbox="allow-scripts allow-same-origin allow-popups allow-modals allow-top-navigation" />'); + $iframe = $('<iframe id="pdframe" style="width:100%;height:100%;display:block;position:absolute;top:0;z-index:1041;" src="'+viewer+'" sandbox="allow-scripts allow-same-origin allow-popups allow-modals allow-top-navigation" allowfullscreen="true"/>'); if(isFileList === true) { FileList.setViewerMode(true); |