Methods

Method for navigating to specific shape based on latitude, longitude and zoom level.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.navigateTo();
    };

    pan(direction)

    Method to perform map panning

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.pan();
    };

    refresh()

    Method to reload the map.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.refresh();
    };

    refreshLayers()

    Method to reload the shapeLayers with updated values

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.refreshLayers();
    };

    refreshNavigationControl(navigation)

    Method to reload the navigation control with updated values.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.refreshNavigationControl();
    };

    zoom(level, isAnimate)

    Method to perform map zooming.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default"></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MapMethod(){
        var mapObj = $("#default").data("ejMap");
        mapObj.zoom();
    };

    Events

    markerSelected

    Triggered on selecting the map markers.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" markerSelected = {MarkerSelected}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function MarkerSelected(){
        // Do Something
    };

    mouseleave

    Triggers while leaving the hovered map shape

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" mouseleave = {Mouseleave}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function Mouseleave(){
        // Do Something
    };

    mouseover

    Triggers while hovering the map shape.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" mouseover = {Mouseover}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function Mouseover(){
        // Do Something
    };

    onRenderComplete

    Triggers once map render completed.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" onRenderComplete = {OnRenderComplete}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function OnRenderComplete(){
        // Do Something
    };

    panned

    Triggers when map panning ends.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" panned = {Panned}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function Panned(){
       // Do Something
    };

    shapeSelected

    Triggered on selecting the map shapes.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" shapeSelected = {ShapeSelected}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function ShapeSelected(){
        // Do Something
    };

    zoomedIn

    Triggered when map is zoomed-in.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" zoomedIn = {ZoomedIn}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function ZoomedIn(){
       // Do Something
    };

    zoomedOut

    Triggers when map is zoomed out.

  • html
  • <div id="map"></div>
  • javascript
  • ReactDOM.render(
        <EJ.Map id="default" zoomedOut = {ZoomedOut}></EJ.Map>,
    	document.getElementById('map')
    );
    
    function ZoomedOut(){
       // Do Something
    };

    Copyright © 2001 - 2015 Syncfusion Inc. All Rights Reserved