diff --git a/source/Ox.UI/js/Map/MapRectangle.js b/source/Ox.UI/js/Map/MapRectangle.js index 70dcaaba..ac43c923 100644 --- a/source/Ox.UI/js/Map/MapRectangle.js +++ b/source/Ox.UI/js/Map/MapRectangle.js @@ -10,12 +10,14 @@ Ox.MapRectangle MapRectangle Object Ox.MapRectangle = function(options) { - var that = this; options = Ox.extend({ map: null, place: null }, options); + var that = this, + themeData = Ox.Theme.getThemeData(); + Ox.forEach(options, function(val, key) { that[key] = val; }); @@ -57,7 +59,11 @@ Ox.MapRectangle = function(options) { } function setOptions() { - var color = that.place.editing ? '#8080FF' : '#FFFFFF'; + var color = '#' + Ox.toHex(themeData[ + that.place.editing + ? 'mapPlaceEditingBorder' + : 'mapPlaceSelectedBorder' + ]); that.rectangle.setOptions({ bounds: that.place.bounds, fillColor: color,