aboutsummaryrefslogtreecommitdiff
path: root/pdf-as-web
diff options
context:
space:
mode:
authorfschneider <florian.schneider@student.tugraz.at>2015-08-06 14:40:23 +0200
committerfschneider <florian.schneider@student.tugraz.at>2015-08-06 14:40:23 +0200
commit0cfb3fe13a2a5280112bf942b4e0b12e5abee1c9 (patch)
tree83ac99c3b55e751fc03cad948b18990ae79e264d /pdf-as-web
parent1e4a0af51ff6b90cca57791b698433d36febb2a5 (diff)
downloadpdf-as-4-0cfb3fe13a2a5280112bf942b4e0b12e5abee1c9.tar.gz
pdf-as-4-0cfb3fe13a2a5280112bf942b4e0b12e5abee1c9.tar.bz2
pdf-as-4-0cfb3fe13a2a5280112bf942b4e0b12e5abee1c9.zip
Preparing for Bootstrap
Diffstat (limited to 'pdf-as-web')
-rw-r--r--pdf-as-web/src/main/webapp/assets/js/dragNdrop.js4
-rw-r--r--pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.css5
-rw-r--r--pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.html1
-rw-r--r--pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.js3
-rw-r--r--pdf-as-web/src/main/webapp/index.jsp8
5 files changed, 14 insertions, 7 deletions
diff --git a/pdf-as-web/src/main/webapp/assets/js/dragNdrop.js b/pdf-as-web/src/main/webapp/assets/js/dragNdrop.js
index c3f340d6..4b605d76 100644
--- a/pdf-as-web/src/main/webapp/assets/js/dragNdrop.js
+++ b/pdf-as-web/src/main/webapp/assets/js/dragNdrop.js
@@ -50,11 +50,11 @@ function registerEventListeners() {
if(files == null || files.length === 0) {
return;
}
- else if(files[0].name.indexOf(".pdf") < 0)
+ /* else if(files[0].name.indexOf(".pdf") < 0)
{
window.alert("The file type must be PDF");
return;
- }
+ } */ // the pdf viewer will handle this
file = files[0];
previewFile();
diff --git a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.css b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.css
index de21f494..84e0f073 100644
--- a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.css
+++ b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.css
@@ -1067,6 +1067,11 @@ html[dir='rtl'] .toolbarButton.pageDown::before {
content: url(images/signature-icon.png);
}
+.toolbarButton.addPage::before,
+.secondaryToolbarButton.addPage::before {
+ content: url(images/signature-icon.png);
+}
+
.toolbarButton.delSignature::before,
.secondaryToolbarButton.delSignature::before {
content: url(images/document_del_signature.png);
diff --git a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.html b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.html
index c6cf575f..1f8a6a44 100644
--- a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.html
+++ b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.html
@@ -225,6 +225,7 @@ http://sourceforge.net/adobe/cmap/wiki/License/
</button>
<!-- ADDED -->
+
<button id="placeSignature" class="toolbarButton placeSignature hiddenLargeView" title="Place Signature on current Page" tabindex="30" data-l10n-id="place_signature">
<span data-l10n-id="place_signature_label">Place Signature</span>
</button>
diff --git a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.js b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.js
index 129823ff..6a2cc14d 100644
--- a/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.js
+++ b/pdf-as-web/src/main/webapp/assets/js/pdf.js/web/viewer.js
@@ -6680,6 +6680,7 @@ function webViewerInitialized() {
var fileInput = document.createElement('input');
fileInput.id = 'fileInput';
+ fileInput.accept = 'application/pdf'
fileInput.className = 'fileInput';
fileInput.setAttribute('type', 'file');
fileInput.oncontextmenu = noContextMenuHandler;
@@ -6861,7 +6862,7 @@ function webViewerInitialized() {
document.getElementById('openFile').addEventListener('click',
SecondaryToolbar.openFileClick.bind(SecondaryToolbar));
-
+
document.getElementById('print').addEventListener('click',
SecondaryToolbar.printClick.bind(SecondaryToolbar));
diff --git a/pdf-as-web/src/main/webapp/index.jsp b/pdf-as-web/src/main/webapp/index.jsp
index abc2ece1..e567e217 100644
--- a/pdf-as-web/src/main/webapp/index.jsp
+++ b/pdf-as-web/src/main/webapp/index.jsp
@@ -16,17 +16,17 @@
</header>
<div id="sidebar">
- <div id="fileSelector" class="container">
+ <!-- <div id="fileSelector" class="container">
<h3 class="center">File Selector</h3>
- <!--<div id="dropzone" class="center">
+ <div id="dropzone" class="center">
Drag and Drop your Document here ...
</div>
<div id="traditionalUpload">
<p>... or select File here</p>
<input type="file" name="pdf-file" id="pdf-file" accept="application/pdf">
- </div> --> <!-- Care: id and name must be unique! -->
+ </div>
- </div>
+ </div> -->
<div id="signMethod" class="container">
<h3 class="center">Sign Method</h3>