fixed background-repeat / background-position problem in IE9 and Opera

This commit is contained in:
MoyuScript
2011-07-17 01:34:34 +03:00
parent 62e96e0683
commit 9680eb64ee
5 changed files with 76 additions and 59 deletions

View File

@@ -13,7 +13,8 @@ function html2canvas(el, userOptions) {
ready: function (canvas) {
document.body.appendChild(canvas);
},
renderViewport: true
flashCanvasPath: "http://html2canvas.hertzen.com/external/flashcanvas/flashcanvas.js",
renderViewport: false
});
this.element = el;
@@ -59,26 +60,25 @@ html2canvas.prototype.init = function(){
this.canvas.width = $(document).width();
this.canvas.height = $(document).height();
if (!this.canvas.getContext){
// TODO include Flashcanvas
/*
var script = document.createElement('script');
script.type = "text/javascript";
script.src = this.opts.flashCanvasPath;
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(script, s);
if (typeof FlashCanvas != "undefined") {
FlashCanvas.initElement(this.canvas);
this.ctx = this.canvas.getContext('2d');
} */
// TODO include Flashcanvas
/*
var script = document.createElement('script');
script.type = "text/javascript";
script.src = "flashcanvas.js";
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(script, s);
if (typeof FlashCanvas != "undefined") {
FlashCanvas.initElement(canvas);
ctx = canvas.getContext('2d');
}
*/
}else{
this.ctx = this.canvas.getContext('2d');
}