[Mapbender-commits] r6027 - trunk/mapbender/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Apr 26 08:33:39 EDT 2010


Author: kmq
Date: 2010-04-26 08:33:38 -0400 (Mon, 26 Apr 2010)
New Revision: 6027

Modified:
   trunk/mapbender/http/javascripts/geometry.js
Log:
give image width and height when drawing via rapha?\195?\171lJS

Modified: trunk/mapbender/http/javascripts/geometry.js
===================================================================
--- trunk/mapbender/http/javascripts/geometry.js	2010-04-26 12:25:51 UTC (rev 6026)
+++ trunk/mapbender/http/javascripts/geometry.js	2010-04-26 12:33:38 UTC (rev 6027)
@@ -1937,7 +1937,11 @@
 				canvas.image(url, newImgLeft, newImgTop, width, height);
 			}
 			else {
-				canvas.image(url, newImgLeft, newImgTop);
+				var $img = $('<img src="'+url+'" />');
+				var width = $img.attr('width')||24;
+				var height = $img.attr('height')||24;
+				canvas.image(url, newImgLeft, newImgTop, width, height);
+				
 			}
 		}
 		else {



More information about the Mapbender_commits mailing list