instead of scrolling the view on every Bounds() call, do it only once

This commit is contained in:
MoyuScript 2011-11-23 14:07:12 +01:00
parent dff5dab161
commit 1792269c01
2 changed files with 1 additions and 3 deletions

View File

@ -36,8 +36,6 @@ html2canvas.Util.backgroundImage = function (src) {
};
html2canvas.Util.Bounds = function getBounds (el) {
window.scroll(0,0);
var clientRect,
bounds = {};

View File

@ -11,7 +11,7 @@
*/
html2canvas.Parse = function (element, images, opts) {
window.scroll(0,0);
opts = opts || {};
// select body by default