cleaned whitespace
This commit is contained in:
parent
76a24d8a5b
commit
54e984c763
1
LICENSE
1
LICENSE
@ -175,4 +175,3 @@
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
|
@ -61,5 +61,3 @@ var viewport = page.getViewport(1);
|
||||
var scale = desiredWidth / viewport.width;
|
||||
var scaledViewport = page.getViewport(scale);
|
||||
```
|
||||
|
||||
|
||||
|
@ -150,4 +150,3 @@ PDFJS.getDocument(pdfWithFormsPath).then(function getPdfForm(pdf) {
|
||||
renderPage(viewer, pdf, pageNumber++, pageRenderingComplete);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -21,7 +21,7 @@
|
||||
// Specify the PDF with AcroForm here
|
||||
var pdfWithFormsPath = '../../test/pdfs/f1040.pdf';
|
||||
</script>
|
||||
|
||||
|
||||
<style>
|
||||
.pdfpage { position:relative; top: 0; left: 0; border: solid 1px black; margin: 10px; }
|
||||
.pdfpage > canvas { position: absolute; top: 0; left: 0; }
|
||||
|
@ -43,4 +43,3 @@ limitations under the License.
|
||||
<script src="pageviewer.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -45,4 +45,3 @@ limitations under the License.
|
||||
<script src="simpleviewer.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
## "Hello World" overview
|
||||
|
||||
This example is a minimalistic application of the pdf.js project. The file
|
||||
This example is a minimalistic application of the pdf.js project. The file
|
||||
`helloworld.pdf` is from the GNUpdf project (see [Introduction to PDF at
|
||||
GNUpdf] (http://gnupdf.org/Introduction_to_PDF)), and contains a simple and
|
||||
human-readable PDF.
|
||||
@ -15,4 +15,3 @@ how to make basic calls to `pdf.js`.
|
||||
## Additional resources
|
||||
|
||||
+ [GNUpdf - Introduction to PDF](http://gnupdf.org/Introduction_to_PDF)
|
||||
|
||||
|
@ -34,4 +34,3 @@ PDFJS.getDocument('helloworld.pdf').then(function(pdf) {
|
||||
page.render(renderContext);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -123,7 +123,7 @@ DOMElement.prototype = {
|
||||
return newNode;
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
global.document = {
|
||||
childNodes : [],
|
||||
|
||||
@ -138,4 +138,3 @@ global.document = {
|
||||
return elObject;
|
||||
},
|
||||
};
|
||||
|
||||
|
@ -63,7 +63,7 @@ PDFJS.getDocument(data).then(function (doc) {
|
||||
var viewport = page.getViewport(1.0 /* scale */);
|
||||
console.log('Size: ' + viewport.width + 'x' + viewport.height);
|
||||
console.log();
|
||||
|
||||
|
||||
return page.getOperatorList().then(function (opList) {
|
||||
var svgGfx = new PDFJS.SVGGraphics(page.commonObjs, page.objs);
|
||||
svgGfx.embedFonts = true;
|
||||
@ -74,7 +74,7 @@ PDFJS.getDocument(data).then(function (doc) {
|
||||
});
|
||||
})
|
||||
};
|
||||
|
||||
|
||||
for (var i = 1; i <= numPages; i++) {
|
||||
lastPromise = lastPromise.then(loadPage.bind(null, i));
|
||||
}
|
||||
@ -84,4 +84,3 @@ PDFJS.getDocument(data).then(function (doc) {
|
||||
}, function (err) {
|
||||
console.error('Error: ' + err);
|
||||
});
|
||||
|
||||
|
@ -26,7 +26,7 @@ PDFJS.getDocument(url).then(function(pdf) {
|
||||
// For testing only.
|
||||
var MAX_NUM_PAGES = 50;
|
||||
var ii = Math.min(MAX_NUM_PAGES, numPages);
|
||||
|
||||
|
||||
var promise = Promise.resolve();
|
||||
for (var i = 1; i <= ii; i++) {
|
||||
var anchor = document.createElement('a');
|
||||
@ -56,4 +56,3 @@ PDFJS.getDocument(url).then(function(pdf) {
|
||||
}.bind(null, i, anchor));
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -272,4 +272,3 @@ limitations under the License.
|
||||
<!-- END STUBS -->
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -1,4 +1,3 @@
|
||||
This is the pdf.js project output, https://github.com/mozilla/pdf.js
|
||||
|
||||
Current extension version is: PDFJSSCRIPT_VERSION
|
||||
|
||||
|
1
extensions/firefox/bootstrap.js
vendored
1
extensions/firefox/bootstrap.js
vendored
@ -203,4 +203,3 @@ function install(aData, aReason) {
|
||||
|
||||
function uninstall(aData, aReason) {
|
||||
}
|
||||
|
||||
|
@ -251,9 +251,9 @@ let PdfJs = {
|
||||
PdfjsChromeUtils.notifyChildOfSettingsChange();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* pdf.js is only enabled if it is both selected as the pdf viewer and if the
|
||||
* pdf.js is only enabled if it is both selected as the pdf viewer and if the
|
||||
* global switch enabling it is true.
|
||||
* @return {boolean} Wether or not it's enabled.
|
||||
*/
|
||||
|
@ -817,7 +817,7 @@ FindEventManager.prototype.handleEvent = function(e) {
|
||||
forward.initCustomEvent(e.type, true, true, detail);
|
||||
// Due to restrictions with cpow use, we can't dispatch
|
||||
// dom events with an urgent message on the stack. So bounce
|
||||
// this off the main thread to make it async.
|
||||
// this off the main thread to make it async.
|
||||
Services.tm.mainThread.dispatch(function () {
|
||||
contentWindow.dispatchEvent(forward);
|
||||
}, Ci.nsIThread.DISPATCH_NORMAL);
|
||||
|
@ -124,7 +124,7 @@
|
||||
// Arabic, Hebrew, Farsi, Pashto, Urdu
|
||||
var rtlList = ['ar', 'he', 'fa', 'ps', 'ur'];
|
||||
|
||||
// use the short language code for "full" codes like 'ar-sa' (issue 5440)
|
||||
// use the short language code for "full" codes like 'ar-sa' (issue 5440)
|
||||
var shortCode = gLanguage.split('-')[0];
|
||||
|
||||
return (rtlList.indexOf(shortCode) >= 0) ? 'rtl' : 'ltr';
|
||||
@ -134,4 +134,3 @@
|
||||
translate: translateFragment
|
||||
};
|
||||
})(this);
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
Most of the files in this folder (except for the `en-US` folder and the
|
||||
`metadata.inc` files) have been imported from the Firefox Aurora branch,
|
||||
which is located at https://mxr.mozilla.org/l10n-mozilla-aurora/source.
|
||||
Some of the files are licensed under the MPL license. You can obtain a
|
||||
Some of the files are licensed under the MPL license. You can obtain a
|
||||
copy of the license at http://mozilla.org/MPL/2.0.
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>يستخدم HTML5 لعرض ملفات PDF مباشره من خلال Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>ফায়ারফক্স এ সরাসরি পিডিএফ দেখানোর জন্যে HTML5 ব্যাবহার করে।</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Používá HTML5 pro zobrazení PDF souborů přímo ve Firefoxu.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Yn defnyddio HTML5 i arddangos ffeiliau PDF yn uniongyrchol yn Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Benytter HTML5 til at vise PDF-filer direkte i Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Nutzt HTML5, um PDFs direkt in Firefox anzuzeigen.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Χρήση HTML5 για εμφάνιση αρχείων PDF κατευθείαν μέσα στο Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Uses HTML5 to display PDF files directly in Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>از اچتیامال۵ برای نمایش پروندههای پیدیاف بهصورت مستقیم در فایرفاکس استفاده میکند.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Näyttää PDF tiedostot suoraan Firefox:ssa HTML5:n avulla.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>הצגת קבצי PDF ישירות ב־Firefox באמצעות HTML5.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Usa HTML5 per visualizzare i file PDF direttamente in Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>HTML5を使用して、Firefoxで直接PDFファイルを表示します。</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Firefox가 PDF 파일을 HTML5를 이용하여 직접 보여줍니다.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>PDF bylos vaizduojamos tiesiogiai, naudojant HTML5 Firefox naršyklėje.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Gebruikt HTML5 om PDF-bestanden direct in Firefox te openen.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Używa HTML5 do wyświetlania plików PDF bezpośrednio w Firefoksie.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Aprensenta PDFs no browser usando a tecnologia HTML5.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Afișează fișierele PDF direct în Firefox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Показывает файлы PDF непосредственно в Firefox используя HTML5.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Користи ХТМЛ5 да би приказао ПДФ датотеке директно у Фајерфоксу.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Firefox içerisinde PDFleri göstermek için HTML5 kullanır.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>Dùng HTML5 để hiện thị PDF trực tiếp trên FireFox.</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>使用 HTML5 来支持在 Firefox 中直接显示 PDF 文件。</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
<em:description>利用 HTML5 技術在 Firefox 中直接顯示 PDF 格式檔案。</em:description>
|
||||
</Description>
|
||||
</em:localized>
|
||||
|
||||
|
@ -19,9 +19,9 @@
|
||||
|
||||
/* This class implements the QM Coder decoding as defined in
|
||||
* JPEG 2000 Part I Final Committee Draft Version 1.0
|
||||
* Annex C.3 Arithmetic decoding procedure
|
||||
* Annex C.3 Arithmetic decoding procedure
|
||||
* available at http://www.jpeg.org/public/fcd15444-1.pdf
|
||||
*
|
||||
*
|
||||
* The arithmetic decoder is used in conjunction with context models to decode
|
||||
* JPEG2000 and JBIG2 streams.
|
||||
*/
|
||||
|
@ -424,4 +424,3 @@ var bidi = PDFJS.bidi = (function bidiClosure() {
|
||||
|
||||
return bidi;
|
||||
})();
|
||||
|
||||
|
@ -116,4 +116,3 @@ var ExpertSubsetCharset = [
|
||||
'eightinferior', 'nineinferior', 'centinferior', 'dollarinferior',
|
||||
'periodinferior', 'commainferior'
|
||||
];
|
||||
|
||||
|
@ -560,4 +560,3 @@ var ChunkedStreamManager = (function ChunkedStreamManagerClosure() {
|
||||
|
||||
return ChunkedStreamManager;
|
||||
})();
|
||||
|
||||
|
@ -530,4 +530,3 @@ var PDFDocument = (function PDFDocumentClosure() {
|
||||
|
||||
return PDFDocument;
|
||||
})();
|
||||
|
||||
|
@ -710,4 +710,3 @@ var FontRendererFactory = (function FontRendererFactoryClosure() {
|
||||
}
|
||||
};
|
||||
})();
|
||||
|
||||
|
@ -2213,4 +2213,3 @@ var JpxImage = (function JpxImageClosure() {
|
||||
|
||||
return JpxImage;
|
||||
})();
|
||||
|
||||
|
@ -2958,4 +2958,3 @@ var Metrics = {
|
||||
'a191': 918
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -274,4 +274,3 @@ var NetworkManager = (function NetworkManagerClosure() {
|
||||
|
||||
return NetworkManager;
|
||||
})();
|
||||
|
||||
|
@ -555,7 +555,7 @@ var Catalog = (function CatalogClosure() {
|
||||
var isPrintAction = (isName(objType) && objType.name === 'Action' &&
|
||||
isName(actionType) && actionType.name === 'Named' &&
|
||||
isName(action) && action.name === 'Print');
|
||||
|
||||
|
||||
if (isPrintAction) {
|
||||
javaScript.push('print(true);');
|
||||
}
|
||||
@ -1411,7 +1411,7 @@ var NameTree = (function NameTreeClosure() {
|
||||
warn('Search depth limit for named destionations has been reached.');
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
var kids = kidsOrNames.get('Kids');
|
||||
if (!isArray(kids)) {
|
||||
return null;
|
||||
@ -1466,10 +1466,10 @@ var NameTree = (function NameTreeClosure() {
|
||||
})();
|
||||
|
||||
/**
|
||||
* "A PDF file can refer to the contents of another file by using a File
|
||||
* "A PDF file can refer to the contents of another file by using a File
|
||||
* Specification (PDF 1.1)", see the spec (7.11) for more details.
|
||||
* NOTE: Only embedded files are supported (as part of the attachments support)
|
||||
* TODO: support the 'URL' file system (with caching if !/V), portable
|
||||
* TODO: support the 'URL' file system (with caching if !/V), portable
|
||||
* collections attributes and related files (/RF)
|
||||
*/
|
||||
var FileSpec = (function FileSpecClosure() {
|
||||
|
@ -222,4 +222,3 @@ var NetworkPdfManager = (function NetworkPdfManagerClosure() {
|
||||
|
||||
return NetworkPdfManager;
|
||||
})();
|
||||
|
||||
|
@ -153,7 +153,7 @@ PDFJS.verbosity = (PDFJS.verbosity === undefined ?
|
||||
PDFJS.VERBOSITY_LEVELS.warnings : PDFJS.verbosity);
|
||||
|
||||
/**
|
||||
* The maximum supported canvas size in total pixels e.g. width * height.
|
||||
* The maximum supported canvas size in total pixels e.g. width * height.
|
||||
* The default value is 4096 * 4096. Use -1 for no limit.
|
||||
* @var {number}
|
||||
*/
|
||||
@ -599,7 +599,7 @@ var PDFDocumentProxy = (function PDFDocumentProxyClosure() {
|
||||
* rendering call the function that is the first argument
|
||||
* to the callback.
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* PDF page operator list.
|
||||
*
|
||||
|
@ -2149,4 +2149,3 @@ var CanvasGraphics = (function CanvasGraphicsClosure() {
|
||||
|
||||
return CanvasGraphics;
|
||||
})();
|
||||
|
||||
|
@ -14,7 +14,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/* globals PDFJS, shadow, isWorker, assert, warn, bytesToString, string32,
|
||||
/* globals PDFJS, shadow, isWorker, assert, warn, bytesToString, string32,
|
||||
globalScope, FontFace, Promise */
|
||||
|
||||
'use strict';
|
||||
|
@ -252,7 +252,7 @@ var SVGExtraState = (function SVGExtraStateClosure() {
|
||||
this.lineJoin = '';
|
||||
this.lineCap = '';
|
||||
this.miterLimit = 0;
|
||||
|
||||
|
||||
this.dashArray = [];
|
||||
this.dashPhase = 0;
|
||||
|
||||
@ -479,7 +479,7 @@ var SVGGraphics = (function SVGGraphicsClosure() {
|
||||
}
|
||||
return opListToTree(opList);
|
||||
},
|
||||
|
||||
|
||||
executeOpTree: function SVGGraphics_executeOpTree(opTree) {
|
||||
var opTreeLen = opTree.length;
|
||||
for(var x = 0; x < opTreeLen; x++) {
|
||||
|
@ -311,4 +311,3 @@ var CFFDictPrivateDataMap = {
|
||||
operand: 0
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -431,4 +431,3 @@ function writeToFile(aBytes, aFilePath) {
|
||||
bos.writeByteArray(aBytes, aBytes.length);
|
||||
stream.close();
|
||||
}
|
||||
|
||||
|
@ -102,7 +102,7 @@ limitations under the License.
|
||||
try {
|
||||
result = test.run();
|
||||
} catch (e) {
|
||||
console.error('test run failed: ' + e);
|
||||
console.error('test run failed: ' + e);
|
||||
result = { output: 'Failed', emulated: '?' };
|
||||
}
|
||||
if (result.then)
|
||||
@ -111,6 +111,6 @@ limitations under the License.
|
||||
publish(result);
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
@ -25,7 +25,7 @@ Promise.prototype = {
|
||||
resolve: function (result) {
|
||||
if ('result' in this) return;
|
||||
this.result = result;
|
||||
if ('callback' in this) this.callback(result);
|
||||
if ('callback' in this) this.callback(result);
|
||||
}
|
||||
};
|
||||
|
||||
@ -665,4 +665,3 @@ function checkCanvas(font) {
|
||||
colors[2][2] * 3 < counts[2][2];
|
||||
return isPlus;
|
||||
}
|
||||
|
||||
|
@ -37,4 +37,3 @@ onmessage = function (e) {
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -99,4 +99,3 @@
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -5,4 +5,3 @@
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
BROWSER_CHROME_MANIFESTS += ['browser.ini']
|
||||
|
||||
|
1
test/resources/browser_manifests/.gitignore
vendored
1
test/resources/browser_manifests/.gitignore
vendored
@ -1,2 +1 @@
|
||||
browser_manifest.json
|
||||
|
||||
|
@ -8,7 +8,7 @@ function MozillaLogger(aPath) {
|
||||
MozillaLogger.prototype = {
|
||||
|
||||
init : function(path) {},
|
||||
|
||||
|
||||
getLogCallback : function() {
|
||||
return function (msg) {
|
||||
var data = msg.num + " " + msg.level + " " + msg.info.join(' ') + "\n";
|
||||
@ -76,7 +76,7 @@ function MozillaFileLogger(aPath) {
|
||||
}
|
||||
|
||||
MozillaFileLogger.prototype = {
|
||||
|
||||
|
||||
init : function (path) {
|
||||
var PR_WRITE_ONLY = 0x02; // Open for writing only.
|
||||
var PR_CREATE_FILE = 0x08;
|
||||
@ -110,7 +110,7 @@ MozillaFileLogger.prototype = {
|
||||
close : function() {
|
||||
if(this._foStream)
|
||||
this._foStream.close();
|
||||
|
||||
|
||||
this._foStream = null;
|
||||
this._file = null;
|
||||
}
|
||||
|
@ -240,10 +240,10 @@ SpecialPowersObserverAPI.prototype = {
|
||||
case "BOOL":
|
||||
if (aMessage.json.op == "get")
|
||||
return(prefs.getBoolPref(prefName));
|
||||
else
|
||||
else
|
||||
return(prefs.setBoolPref(prefName, prefValue));
|
||||
case "INT":
|
||||
if (aMessage.json.op == "get")
|
||||
if (aMessage.json.op == "get")
|
||||
return(prefs.getIntPref(prefName));
|
||||
else
|
||||
return(prefs.setIntPref(prefName, prefValue));
|
||||
@ -297,7 +297,7 @@ SpecialPowersObserverAPI.prototype = {
|
||||
break;
|
||||
case "has":
|
||||
let hasPerm = Services.perms.testPermissionFromPrincipal(principal, msg.type);
|
||||
if (hasPerm == Ci.nsIPermissionManager.ALLOW_ACTION)
|
||||
if (hasPerm == Ci.nsIPermissionManager.ALLOW_ACTION)
|
||||
return true;
|
||||
return false;
|
||||
break;
|
||||
@ -411,4 +411,3 @@ SpecialPowersObserverAPI.prototype = {
|
||||
return undefined;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -695,7 +695,7 @@ SpecialPowersAPI.prototype = {
|
||||
we will revert the permission back to the original.
|
||||
|
||||
inPermissions is an array of objects where each object has a type, action, context, ex:
|
||||
[{'type': 'SystemXHR', 'allow': 1, 'context': document},
|
||||
[{'type': 'SystemXHR', 'allow': 1, 'context': document},
|
||||
{'type': 'SystemXHR', 'allow': Ci.nsIPermissionManager.PROMPT_ACTION, 'context': document}]
|
||||
|
||||
Allow can be a boolean value of true/false or ALLOW_ACTION/DENY_ACTION/PROMPT_ACTION/UNKNOWN_ACTION
|
||||
@ -1706,7 +1706,7 @@ SpecialPowersAPI.prototype = {
|
||||
var msg = {
|
||||
'op': 'test',
|
||||
'type': type,
|
||||
'value': value,
|
||||
'value': value,
|
||||
'url': url,
|
||||
'appId': appId,
|
||||
'isInBrowserElement': isInBrowserElement
|
||||
|
@ -330,7 +330,7 @@ function objEquiv(a, b) {
|
||||
// The same set of keys (although not necessarily the same order),
|
||||
ka.sort();
|
||||
kb.sort();
|
||||
// Equivalent values for every corresponding key, and possibly expensive deep
|
||||
// Equivalent values for every corresponding key, and possibly expensive deep
|
||||
// test
|
||||
for (i = ka.length - 1; i >= 0; i--) {
|
||||
key = ka[i];
|
||||
|
@ -49,10 +49,10 @@ this.MockPermissionPrompt = {
|
||||
registrar.registerFactory(newClassID, "", CONTRACT_ID, newFactory);
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
reset: function() {
|
||||
},
|
||||
|
||||
|
||||
cleanup: function() {
|
||||
this.reset();
|
||||
if (oldFactory) {
|
||||
|
@ -8,7 +8,7 @@
|
||||
<em:version>2010.07.23</em:version>
|
||||
<em:type>2</em:type>
|
||||
|
||||
<!-- Target Application this extension can install into,
|
||||
<!-- Target Application this extension can install into,
|
||||
with minimum and maximum supported versions. -->
|
||||
<em:targetApplication>
|
||||
<Description>
|
||||
@ -22,5 +22,5 @@
|
||||
<em:name>Special Powers</em:name>
|
||||
<em:description>Special powers for use in testing.</em:description>
|
||||
<em:creator>Mozilla</em:creator>
|
||||
</Description>
|
||||
</Description>
|
||||
</RDF>
|
||||
|
@ -96,11 +96,11 @@ Original author: L. David Baron <dbaron@dbaron.org>
|
||||
<form id="imgcontrols">
|
||||
<label>
|
||||
<input type="radio" name="which" id="testImage" value="0" checked="checked"> Test
|
||||
</label>
|
||||
</label>
|
||||
<label>
|
||||
<input type="radio" name="which" id="referenceImage" value="1"> Reference
|
||||
</label>
|
||||
<label>
|
||||
<label>
|
||||
<input type="checkbox" id="differences"> Circle differences
|
||||
</label>
|
||||
</form>
|
||||
@ -146,12 +146,12 @@ Original author: L. David Baron <dbaron@dbaron.org>
|
||||
<feComposite result="c" in="c1" in2="c2" operator="arithmetic" k2="255" k3="255" />
|
||||
<!-- a will be opaque for every pixel with differences and transparent for all others -->
|
||||
<feColorMatrix result="a" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0" />
|
||||
|
||||
|
||||
<!-- a, dilated by 4 pixels -->
|
||||
<feMorphology result="dila4" in="a" operator="dilate" radius="4" />
|
||||
<!-- a, dilated by 1 pixel -->
|
||||
<feMorphology result="dila1" in="a" operator="dilate" radius="1" />
|
||||
|
||||
|
||||
<!-- all the pixels in the 3-pixel dilation of a but not in the 1-pixel dilation of a, to highlight the diffs -->
|
||||
<feComposite result="highlight" in="dila4" in2="dila1" operator="out" />
|
||||
|
||||
|
@ -68,7 +68,7 @@ window.onload = function() {
|
||||
ID("logEntry").value = params.log;
|
||||
logPasted();
|
||||
} else if (params.web) {
|
||||
loadFromWeb(params.web);
|
||||
loadFromWeb(params.web);
|
||||
}
|
||||
ID("logEntry").focus();
|
||||
}
|
||||
@ -189,7 +189,7 @@ window.onload = function() {
|
||||
var random = match[2];
|
||||
var url = match[3];
|
||||
var extra = match[4];
|
||||
|
||||
|
||||
gTestItems.push({
|
||||
pass: !state.match(/FAIL$/),
|
||||
// only one of the following three should ever be true
|
||||
@ -220,7 +220,7 @@ window.onload = function() {
|
||||
var table = document.getElementById("itemtable");
|
||||
while (table.childNodes.length > 0) {
|
||||
table.removeChild(table.childNodes[table.childNodes.length - 1]);
|
||||
}
|
||||
}
|
||||
var tbody = document.createElement("tbody");
|
||||
table.appendChild(tbody);
|
||||
|
||||
@ -234,7 +234,7 @@ window.onload = function() {
|
||||
var rowclass = item.pass ? "pass" : "fail";
|
||||
var td = document.createElement("td");
|
||||
var text = "";
|
||||
|
||||
|
||||
if (item.unexpected) {
|
||||
text += "!";
|
||||
rowclass += " unexpected";
|
||||
@ -253,7 +253,7 @@ window.onload = function() {
|
||||
td = document.createElement("td");
|
||||
td.id = "url" + i;
|
||||
td.className = "url";
|
||||
|
||||
|
||||
var match = item.url.match(/\/mozilla\/(.*)/);
|
||||
text = document.createTextNode(match ? match[1] : item.url);
|
||||
if (item.images.length > 0) {
|
||||
|
1
test/stats/results/.gitignore
vendored
1
test/stats/results/.gitignore
vendored
@ -2,4 +2,3 @@
|
||||
*
|
||||
# Except this file
|
||||
!.gitignore
|
||||
|
||||
|
@ -45,4 +45,3 @@ limitations under the License.
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -108,4 +108,3 @@ describe('cmap', function() {
|
||||
expect(cmap.builtInCMap).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -229,4 +229,3 @@ describe('evaluator', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -520,4 +520,3 @@ describe('function', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -148,4 +148,3 @@ describe('obj', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -74,4 +74,3 @@ describe('parser', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -41,4 +41,3 @@ describe('stream', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -104,4 +104,3 @@
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
@ -78,4 +78,3 @@ describe('util', function() {
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
@ -152,7 +152,7 @@ var DocumentProperties = {
|
||||
|
||||
parseDate: function documentPropertiesParseDate(inputDate) {
|
||||
// This is implemented according to the PDF specification (see
|
||||
// http://www.gnupdf.org/Date for an overview), but note that
|
||||
// http://www.gnupdf.org/Date for an overview), but note that
|
||||
// Adobe Reader doesn't handle changing the date to universal time
|
||||
// and doesn't use the user's time zone (they're effectively ignoring
|
||||
// the HH' and mm' parts of the date string).
|
||||
|
@ -89,7 +89,7 @@ var DownloadManager = (function DownloadManagerClosure() {
|
||||
downloadData: function DownloadManager_downloadData(data, filename,
|
||||
contentType) {
|
||||
var blobUrl = PDFJS.createObjectURL(data, contentType);
|
||||
|
||||
|
||||
FirefoxCom.request('download', {
|
||||
blobUrl: blobUrl,
|
||||
originalUrl: blobUrl,
|
||||
|
@ -163,4 +163,3 @@ var PDFFindBar = (function PDFFindBarClosure() {
|
||||
};
|
||||
return PDFFindBar;
|
||||
})();
|
||||
|
||||
|
@ -301,7 +301,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
||||
if (this.pagesToSearch < 0) {
|
||||
// No point in wrapping again, there were no matches.
|
||||
this.updateMatch(false);
|
||||
// while matches were not found, searching for a page
|
||||
// while matches were not found, searching for a page
|
||||
// with matches should nevertheless halt.
|
||||
return true;
|
||||
}
|
||||
@ -354,7 +354,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
||||
offset.matchIdx = null;
|
||||
|
||||
this.pagesToSearch--;
|
||||
|
||||
|
||||
if (offset.pageIdx >= numPages || offset.pageIdx < 0) {
|
||||
offset.pageIdx = (previous ? numPages - 1 : 0);
|
||||
offset.wrapped = true;
|
||||
@ -365,7 +365,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
||||
var state = FindStates.FIND_NOTFOUND;
|
||||
var wrapped = this.offset.wrapped;
|
||||
this.offset.wrapped = false;
|
||||
|
||||
|
||||
if (found) {
|
||||
var previousPage = this.selected.pageIdx;
|
||||
this.selected.pageIdx = this.offset.pageIdx;
|
||||
@ -376,7 +376,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
||||
this.updatePage(previousPage);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
this.updateUIState(state, this.state.findPrevious);
|
||||
if (this.selected.pageIdx !== -1) {
|
||||
this.updatePage(this.selected.pageIdx);
|
||||
@ -398,4 +398,3 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
||||
};
|
||||
return PDFFindController;
|
||||
})();
|
||||
|
||||
|
@ -190,7 +190,7 @@ http://sourceforge.net/adobe/cmap/wiki/License/
|
||||
<button id="toggleHandTool" class="secondaryToolbarButton handTool" title="Enable hand tool" tabindex="60" data-l10n-id="hand_tool_enable">
|
||||
<span data-l10n-id="hand_tool_enable_label">Enable hand tool</span>
|
||||
</button>
|
||||
|
||||
|
||||
<div class="horizontalToolbarSeparator"></div>
|
||||
|
||||
<button id="documentProperties" class="secondaryToolbarButton documentProperties" title="Document Properties…" tabindex="61" data-l10n-id="document_properties">
|
||||
@ -245,10 +245,10 @@ http://sourceforge.net/adobe/cmap/wiki/License/
|
||||
</a>
|
||||
|
||||
<div class="verticalToolbarSeparator hiddenSmallView"></div>
|
||||
|
||||
|
||||
<button id="secondaryToolbarToggle" class="toolbarButton" title="Tools" tabindex="36" data-l10n-id="tools">
|
||||
<span data-l10n-id="tools_label">Tools</span>
|
||||
</button>
|
||||
</button>
|
||||
</div>
|
||||
<div class="outerCenter">
|
||||
<div class="innerCenter" id="toolbarViewerMiddle">
|
||||
|
Loading…
Reference in New Issue
Block a user