Merge pull request #1569 from yurydelendik/issue-1555

Fixes page-width mode
This commit is contained in:
Brendan Dahl 2012-04-17 14:29:29 -07:00
commit ed6e440c71

View File

@ -247,9 +247,9 @@ var PDFView = {
var currentPage = this.pages[this.page - 1]; var currentPage = this.pages[this.page - 1];
var pageWidthScale = (window.innerWidth - kScrollbarPadding) / var pageWidthScale = (window.innerWidth - kScrollbarPadding) /
currentPage.width / kCssUnits; currentPage.width * currentPage.scale / kCssUnits;
var pageHeightScale = (window.innerHeight - kScrollbarPadding) / var pageHeightScale = (window.innerHeight - kScrollbarPadding) /
currentPage.height / kCssUnits; currentPage.height * currentPage.scale / kCssUnits;
if ('page-width' == value) if ('page-width' == value)
this.setScale(pageWidthScale, resetAutoSettings); this.setScale(pageWidthScale, resetAutoSettings);
if ('page-height' == value) if ('page-height' == value)