]> git.parisson.com Git - pdf.js.git/commitdiff
Hide the browse bar for the ff extension.
authorBrendan Dahl <brendan.dahl@gmail.com>
Tue, 24 Jan 2012 23:13:50 +0000 (15:13 -0800)
committerBrendan Dahl <brendan.dahl@gmail.com>
Tue, 24 Jan 2012 23:13:50 +0000 (15:13 -0800)
web/viewer.css
web/viewer.html
web/viewer.js

index e355f7fc246cf3cb8c3a360a475c9cc3708a2060..b9fd3e9e436843353dac154340dda6b63dc6b79e 100644 (file)
@@ -9,7 +9,7 @@ body {
 }
 
 [hidden] {
-  display: none;
+  display: none !important;
 }
 
 /* === Toolbar === */
index f395292f98d356b87b0a03f712b6bb3f768fbd36..ad9d1189e81d7c2367381cf5a5c86d4c86db4f02 100644 (file)
@@ -92,7 +92,7 @@
 
       <input id="fileInput" type="file" oncontextmenu="return false;"/>
 
-      <div class="separator"></div>
+      <div id="fileInputSeperator" class="separator"></div>
 
       <a href="#" id="viewBookmark" title="Bookmark (or copy) current location">
         <img src="images/bookmark.svg" alt="Bookmark" align="top" height="16"/>
index 1ed9019ffbfe14a51783f34a7a5c1bfb98393f43..131d12b42ed18457de330128cb0d1a216e5cbdea 100644 (file)
@@ -995,10 +995,14 @@ window.addEventListener('load', function webViewerLoad(evt) {
               window.location.toString() : params.file || kDefaultURL;
   PDFView.open(file, parseFloat(scale));
 
-  if (!window.File || !window.FileReader || !window.FileList || !window.Blob)
+  if (PDFJS.isFirefoxExtension || !window.File || !window.FileReader ||
+      !window.FileList || !window.Blob) {
     document.getElementById('fileInput').setAttribute('hidden', 'true');
-  else
+    document.getElementById('fileInputSeperator')
+                              .setAttribute('hidden', 'true');
+  } else {
     document.getElementById('fileInput').value = null;
+  }
 
   if ('disableWorker' in params)
     PDFJS.disableWorker = (params['disableWorker'] === 'true');