[geojquery] To plug in or not to plug in?

Oliver Tonnhofer olt at bogosoft.com
Sun Mar 14 05:48:31 EDT 2010


On 13.03.2010, at 21:48, Volker Mische wrote:
> the way I have imagined it is like gquery does it. Once you apply the
> map object, you are not in the DOM world any more. Any future call in
> the chain will be applied to the map. Here's an example:
> 
> $('#map').map({someoptions}).center(lonlat);
> [...]
> $('#map').map({someoptions}).center(lonlat).dom().hide();


Ok, that looks not to bad. How do you think we retrieve the map object again later? We could store the object with .data() and return this object on subsequent .map() calls.

$('#map').map({someoptions})
// later
$('#map').map().center(lonlat);

It would be cool to have working CSS selectors like
$('#map #mylayer').hide(). It might work some custom selectors $('#map :layer("mylayer")').layer().disable()

Regards,
Oliver

-- 
Oliver Tonnhofer <tonnhofer at omniscale.de>
Omniscale - Dominik Helle, Oliver Tonnhofer GbR
Nadorster Str. 60, 26123 Oldenburg
Tel: +49(0)441/9392774-2 (Fax: 9)





More information about the Geojquery mailing list