JC Flash Map Events



Overview | Properties | Methods | Events | Markers

Event Description
MapEvent.MAP_CLICKED Event dispatched when the user clicks on the map area but not on the markers.

Example
import com.jumpeye.Events.MapEvent;

myMap.addEventListener(MapEvent.MAP_CLICKED, mapClickHandler);

function mapClickHandler(evtObj:MapEvent):void {
    trace("Center of the map is at ("+evtObj.lat+", "+evtObj.lng+") latitude and longitude");
}
MapEvent.MAP_MOVED Event dispatched when the map finished moving (after a mouse up event). The parameters received from the event object are the new coordinates (latitude/longitude) of the map's center.

Example
import com.jumpeye.Events.MapEvent;

myMap.addEventListener(MapEvent.MAP_MOVED, mapMoveHandler);

function mapMoveHandler(evtObj:MapEvent):void {
    trace("Center of the map is now at ("+evtObj.lat+", "+evtObj.lng+") latitude and longitude");
}
MapEvent.MAP_TYPE_CHANGED Event dispatched when the map type has changed.

Example
import com.jumpeye.Events.MapEvent;

myMap.addEventListener(MapEvent. MAP_TYPE_CHANGED, typeHandler);

function typeHandler(evtObj:MapEvent):void {
    trace("The new map type is "+evtObj.mapType. name);
}
MapEvent.ZOOM_CHANGED Event dispatched before the zoom animation.

Example
import com.jumpeye.Events.MapEvent;

myMap.addEventListener(MapEvent.ZOOM_CHANGED, zoomHandler);

function zoomHandler(evtObj:MapEvent):void {
     trace("The new zoom level is "+evtObj.zoom);
}

Overview | Properties | Methods | Events | Markers