To get all the active controls:
var active = map.getControlsBy('active',true);
To deactivate all of them:
for (var i = 0; i < active.length; i++) {
active.deactivate();
}
z
On Mon, Sep 13, 2010 at 11:34 AM, Planet)x <[email protected]>wrote:
>
> Can this be done, I am trying to put the name of the control into a string
> to
> display which control is active. I came across the getControlsBy which is
> supposed to get a list of controls with properties matching the given
> criteria but not sure how to send the getActive as a criteria for this.
> Also
> is there an easy way to make no tool active on my control panel ?
> Appreciate
> any assistance.
>
> --
> View this message in context:
> http://osgeo-org.1803224.n2.nabble.com/Getting-the-active-control-of-a-control-panel-tp5526778p5526778.html
> Sent from the OpenLayers Users mailing list archive at Nabble.com.
> _______________________________________________
> Users mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users