[Mapbender-dev] motion: change attribute "extent" of map

Astrid Emde astrid.emde at wheregroup.com
Tue Jun 2 12:11:33 EDT 2009


Christoph Baudson schrieb:
> Currently, this is a string containing four comma-separated 
> coordinates. This is hard to use, whenever you want to perform an 
> operation on the extent, you have to split the string and use 
> parseFloat. There is also no way to register an event with the setting 
> of the extent, because it's not a function.
>
> At the development sprint in Hannover Peter and I discussed the 
> implementation of a restricted extent. For this, we concluded, using 
> the Extent object as attribute (and no longer the string) would be 
> necessary. I am changing this in trunk, if this motion passes. The 
> changes would include
>
> (1) The extent attribute is currently *set* by
>
> map.extent = "a,b,c,d";
>
> The new version would use this syntax
>
> map.extent = new Extent(a,b,c,d);
>
>
> (2) The extent attribute is currently *read* by
>
> map.extent
>
> which is a string "a,b,c,d". The new version would use this syntax
>
> map.extent.toString();
>
> and return the same string "a,b,c,d".
>
>
> All custom modules would have to use these changes as well, which will 
> be important when updating. I'll only change the modules in Mapbender 
> trunk.
>
> Please second this motion and vote.
>
> Christoph
>
Hi Christoph,

 this idea sound good.

+1 from  me

Astrid


More information about the Mapbender_dev mailing list