From 718d84d6d28909911fe76ba0a3ef262b4b53b26f Mon Sep 17 00:00:00 2001 From: euzuro Date: Tue, 4 Jul 2006 15:30:11 +0000 Subject: [PATCH] when cloning an icon, set the calculateOffset() function too, if it exists. git-svn-id: http://svn.openlayers.org/trunk/openlayers@877 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- lib/OpenLayers/Icon.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/OpenLayers/Icon.js b/lib/OpenLayers/Icon.js index aa33b195d7..f0c8d93e69 100644 --- a/lib/OpenLayers/Icon.js +++ b/lib/OpenLayers/Icon.js @@ -53,7 +53,10 @@ OpenLayers.Icon.prototype = { * @type OpenLayers.Icon */ clone: function() { - return new OpenLayers.Icon(this.url, this.size, this.offset); + return new OpenLayers.Icon(this.url, + this.size, + this.offset, + this.calculateOffset); }, /**