How do I display a image directly on my map? I would like to place my logo above the Scalebar widget. I assume you need to make an off-panel widget, so I was looking at the other off panel widgets. I noticed the way the coordinate widget displays itself is in the postCreate function:
postCreate: function() {
this.inherited(arguments);
domClass.add(this.coordinateBackground, "coordinate-background");
this.own(on(this.map, "extent-change", lang.hitch(this, this.onExtentChange)));
this.own(on(this.map, "mouse-move", lang.hitch(this, this.onMouseMove)));
this.own(on(this.map, "click", lang.hitch(this, this.onMapClick)));
this.own(on(this.locateButton, "click", lang.hitch(this, this.onLocateButtonClick)));
this.own(on(this.foldContainer, 'click', lang.hitch(this, this.onFoldContainerClick)));
this.graphicsLayer = new GraphicsLayer();
this.map.addLayer(this.graphicsLayer);
}
They appear to be using either domClass.add or a GraphicsLayer. Where can i find more information about these Objects? Esri's GraphicLayer API documentation doesn't mention the addLayer that is used in this widget, and the domClass.add seems to be depreciated.
Does the image need to be placed in reference to a specific geographic coordinate or place in reference to the map element? If there is no geographic component to the image, you can just create an img element and place at the appropriate location. No need to add a graphics layer to the map. We have a compass rose widget that does this and it works just fine.