Merge pull request #29 from gatapia/patch-1

It is possible for image tags not to have a 'src' (or background-image) ...
This commit is contained in:
Niklas von Hertzen 2011-11-15 04:12:37 -08:00
commit 74c7373362

View File

@ -250,7 +250,10 @@ html2canvas.Preload = function(element, opts){
// load <img> images
for (i = 0; i < imgLen; i+=1){
methods.loadImage( domImages[i].getAttribute( "src" ) );
var imgSrc = domImages[i].getAttribute( "src" );
if ( imgSrc ) {
methods.loadImage( imgSrc );
}
}
// remove 'start'