1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-20 15:18:08 +02:00

Merge branch 'master' of github.com:mozilla/pdf.js into textsearch

This commit is contained in:
Artur Adib 2012-05-16 12:51:19 -04:00
commit 0bac4abcb5
22 changed files with 675 additions and 78 deletions

View file

@ -1179,7 +1179,8 @@ var PageView = function pageView(container, pdfPage, id, scale,
var ThumbnailView = function thumbnailView(container, pdfPage, id) {
var anchor = document.createElement('a');
anchor.href = PDFView.getAnchorUrl('#page=' + id);
anchor.onclick = function stopNivigation() {
anchor.title = mozL10n.get('thumb_page_title', {page: id}, 'Page {{page}}');
anchor.onclick = function stopNavigation() {
PDFView.page = id;
return false;
};
@ -1212,6 +1213,8 @@ var ThumbnailView = function thumbnailView(container, pdfPage, id) {
canvas.width = canvasWidth;
canvas.height = canvasHeight;
canvas.className = 'thumbnailImage';
canvas.setAttribute('aria-label', mozL10n.get('thumb_page_canvas',
{page: id}, 'Thumbnail of Page {{page}}'));
div.setAttribute('data-loaded', true);
@ -1468,11 +1471,12 @@ window.addEventListener('load', function webViewerLoad(evt) {
if ('disableWorker' in hashParams)
PDFJS.disableWorker = (hashParams['disableWorker'] === 'true');
var locale = !PDFJS.isFirefoxExtension ? navigator.language :
FirefoxCom.request('getLocale', null);
if ('locale' in hashParams)
locale = hashParams['locale'];
mozL10n.language.code = locale;
if (!PDFJS.isFirefoxExtension) {
var locale = navigator.language;
if ('locale' in hashParams)
locale = hashParams['locale'];
mozL10n.language.code = locale;
}
if ('disableTextLayer' in hashParams)
PDFJS.disableTextLayer = (hashParams['disableTextLayer'] === 'true');