Fixes canvas alignment for small scale and scale adjustment after Cmd+0
This commit is contained in:
parent
e5cd027dce
commit
86077810b0
@ -1102,7 +1102,7 @@ html[dir='rtl'] .outlineItem > a {
|
|||||||
}
|
}
|
||||||
|
|
||||||
canvas {
|
canvas {
|
||||||
margin: auto;
|
margin: 0;
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2765,8 +2765,12 @@ window.addEventListener('keydown', function keydown(evt) {
|
|||||||
break;
|
break;
|
||||||
case 48: // '0'
|
case 48: // '0'
|
||||||
case 96: // '0' on Numpad of Swedish keyboard
|
case 96: // '0' on Numpad of Swedish keyboard
|
||||||
PDFView.parseScale(DEFAULT_SCALE, true);
|
// keeping it unhandled (to restore page zoom to 100%)
|
||||||
handled = false; // keeping it unhandled (to restore page zoom to 100%)
|
setTimeout(function () {
|
||||||
|
// ... and resetting the scale after browser adjusts its scale
|
||||||
|
PDFView.parseScale(DEFAULT_SCALE, true);
|
||||||
|
});
|
||||||
|
handled = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user