Select to view content in your preferred language

Navigation zoomin/zoomout events

502
1
02-07-2011 05:15 AM
TyroneLigon
Deactivated User
Using the 1.3 API and dynamic map services; is there a way to configure the zoomin/zoomout events on the navigation slider?  When you click the "zoomin" button, the map scale is halved; when you click the "zoomout" button, the map scale is doubled. Other than writing listener code for the navigation zoomin/zoomout events, is there a way to set the zoom factors for these events?
Tags (2)
0 Kudos
1 Reply
DasaPaddock
Esri Regular Contributor
The Map calls it's zoomIn() and zoomOut() methods when the Navigation control dispatches zoomIn/out. You could extend Map and override those methods.

e.g.

package comp
{

import com.esri.ags.Map;

public class MyMap extends Map
{
    override public function zoomIn():void
    {
        extent = extent.expand(0.75);
    }

    override public function zoomOut():void
    {
        extent = extent.expand(1.5);
    }
}

}
0 Kudos