set default pixelRatio for method

This commit is contained in:
Anton Lavrenov
2015-04-27 11:20:55 +07:00
parent 744dd61992
commit 3dff461592
4 changed files with 38 additions and 28 deletions

View File

@@ -281,6 +281,7 @@ suite('Node', function() {
// ======================================================
test('toDataURL + HDPI', function(done) {
this.timeout(5000);
var oldRatio = Konva.pixelRatio;
Konva.pixelRatio = 2;
@@ -301,6 +302,7 @@ suite('Node', function() {
stage.draw();
stage.toDataURL({
pixelRatio : 2,
callback : function(url) {
var img = new Image();
img.onload = function() {