adding markup tools to custom module
I am developing a custom JS module for our HTML5 viewer which requires the user to choose a markup tool to define an area on the map.
I have been able to get this to work by creating a button which, when clicked, gets a reference to the ESRI Draw toolbar and setting the appropriate drawing type (point, line, poly), however there is no indication that the tool has become active like there is when using the default HTML5 viewer markup tools (i.e. the tooltip doesn't appear at the bottom of the map telling the user to define an area) and the ability to draw the feature using keyboard commands (for WCAG accessibility compliance) is not available. Here is the basic code snippet that I'm using to set the draw tool:
if (this.drawToolBar == null) {
this.esriMap = this.app.site.essentialsMap.getMap();
this.drawToolBar = new esri.toolbars.Draw(this.esriMap);
this.drawToolBar.on("draw-end", this.drawToolEnd);
}
this.drawToolBar.activate("circle");
Is there another way to make use of the Geocortex markup commands rather than using the ESRI draw toolbar? I haven't been able to find anything in the limited JS documentation for the HTML5 viewer.
Thanks,
Peter.
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
0 Kommentare