From ab9d07501e4c739d660a126d1e2951b00c335be2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Lehni?= Date: Wed, 2 Mar 2011 16:08:11 +0000 Subject: [PATCH] Simplify code a bit, by chainging variable declarations. --- src/item/Raster.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/item/Raster.js b/src/item/Raster.js index 8500afb4..257d8f2c 100644 --- a/src/item/Raster.js +++ b/src/item/Raster.js @@ -157,16 +157,16 @@ Raster = Item.extend({ // Now rotate the corner points of the image rectangle do find the // extremas that define our raster's bounds, and update them straight // away - var width = this._size.width; - var height = this._size.height; - var x = -width / 2; - var y = -height / 2; - var coords = [ + var width = this._size.width, + height = this._size.height, + x = -width / 2, + y = -height / 2, + coords = [ x, y, x + width, y, x + width, y + height, x, y + height - ]; + ]; this.matrix.transform(coords, 0, coords, 0, 4); // Loop through all x and y coordinates and update min and max values. // Start with the first coordinate pair for both (coords.slice(0, 2)).