diff options
-rw-r--r-- | .gitignore | 59 | ||||
-rw-r--r-- | .travis.yml | 2 | ||||
-rw-r--r-- | appinfo/info.xml | 2 | ||||
-rw-r--r-- | js/previewplugin.js | 2 | ||||
-rw-r--r-- | js/workersrc.js | 4 |
5 files changed, 66 insertions, 3 deletions
diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..de542ff --- /dev/null +++ b/.gitignore @@ -0,0 +1,59 @@ +# just sane ignores +.*.sw[po] +*.bak +*.BAK +*~ +*.orig +*.class +.cvsignore +Thumbs.db +*.py[co] +_darcs/* +CVS/* +.svn/* +RCS/* +*.backup* + +# kdevelop +.kdev +*.kdev4 +*.kate-swp + +# Lokalize +*lokalize* + +# eclipse +.project +.settings + +# netbeans +nbproject + +# phpStorm +.idea +*.iml + +# geany +*.geany + +# Cloud9IDE +.settings.xml +.c9revisions + +# vim ex mode +.vimrc + +# Mac OS +.DS_Store + +# WebFinger +.well-known +/.buildpath + +# Tests - auto-generated files +/PhantomJS_* +/tests/coverage* +/tests/clover.xml +/tests/js/node_modules +/tests/js/run.sh +/tests/karma-coverage diff --git a/.travis.yml b/.travis.yml index 8836899..7525a59 100644 --- a/.travis.yml +++ b/.travis.yml @@ -18,7 +18,7 @@ branches: before_install: - wget https://raw.githubusercontent.com/nextcloud/travis_ci/master/before_install.sh - - bash ./before_install.sh $APP_NAME $CORE_BRANCH $DB + - . ./before_install.sh $APP_NAME $CORE_BRANCH $DB # Add some output debugging information - cd ../server diff --git a/appinfo/info.xml b/appinfo/info.xml index 8949f0b..3e6f895 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -17,7 +17,7 @@ about the PDF.js project at [https://mozilla.github.io/pdf.js/](https://mozilla. </description> <licence>AGPL</licence> <author>Thomas Müller, Lukas Reschke</author> - <version>1.1.0</version> + <version>1.1.1</version> <dependencies> <nextcloud min-version="12" max-version="12" /> </dependencies> diff --git a/js/previewplugin.js b/js/previewplugin.js index 2e71996..e5518b4 100644 --- a/js/previewplugin.js +++ b/js/previewplugin.js @@ -46,7 +46,7 @@ var self = this; 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:141;" src="'+viewer+'" sandbox="allow-scripts allow-same-origin allow-popups allow-modals" />'); + $iframe = $('<iframe id="pdframe" style="width:100%;height:100%;display:block;position:absolute;top:0;z-index:141;" src="'+viewer+'" sandbox="allow-scripts allow-same-origin allow-popups allow-modals allow-top-navigation" />'); if(isFileList === true) { FileList.setViewerMode(true); diff --git a/js/workersrc.js b/js/workersrc.js index 7e4079f..2aa186b 100644 --- a/js/workersrc.js +++ b/js/workersrc.js @@ -15,3 +15,7 @@ redirectIfNotDisplayedInFrame(); PDFJS.openExternalLinksInNewWindow = true; PDFJS.isEvalSupported = false; PDFJS.workerSrc = document.getElementsByTagName('head')[0].getAttribute('data-workersrc'); + +PDFViewerApplication.download = function() { + window.open(decodeURIComponent(window.location.search.substr(6)), '_blank'); +};
\ No newline at end of file |