Client Views Simple Map

The Simple Map View is a cut down map view that allows you to add additional map views to your client config.

It is currently an experimental client component and has a number of limitations.

  • It can't be the first map view displayed, for now it needs to be used in a tab region and have the main map tab be the first visible one and this new map view on a different tab.
  • There are no tool bars or status bars available, which also means that you can't use any of the existing tools, zoom, pan, select, etc, so if you want the users to be able to pan/zoom around the map you'll need to add controls to the view (com.cohga.client.mapctrl.navigation or com.cohga.client.mapctrl.panZoomBar). 
    • The main map view and the simple map view should remain in sync when panning/zooming around.
    • Other map controls may or may not work (they should but who knows how they'll interact with the other map view).
  • You have no control over what layers are displayed on the map aside from specifying the map engines to be used within the map, all layers within the map engines listed in the view will be turned on.
    • You can control exactly what layers are displayed by setting up the required map engines with just the layers you want to have displayed. 
    • Setting isBaseLayer to true will place the map engine into a group where only one of the group can be turned on at a time.
  • You can't use map engines in this view that are used in the main map view, because when the simple map view is shown it turns on all the layers in the underlying map engine, which causes the layers to all be turned on in the main map view if it's using the same map engine.
Example client view config
<view id="com.cohga.html.client.map.simpleMapView">
	<label>Imagery</label>
	<location>center</location>
	<control id="weave.mapctrl.keyboard"/>
	<control id="com.cohga.client.mapctrl.touch"/>
	<control id="com.cohga.client.mapctrl.navigation"/>
	<control id="com.cohga.client.mapctrl.mousePosition"/>
	<control id="com.cohga.client.mapctrl.panZoomBar"/>
	<control id="com.cohga.client.mapctrl.layerSwitcher" maximized="true" baseLabel="Raster" dataLabel="Vector"/>
	<mapengine id="mapengine.floods">
		<options>
			<label>Floods</label>
			<isBaseLayer>true</isBaseLayer>
		</options>
	</mapengine>
	<mapengine id="mapengine.planning">
		<options>
			<label>Planning</label>
			<isBaseLayer>true</isBaseLayer>
		</options>
	</mapengine>
	<mapengine id="mapengine.rail">
		<options>
			<label>Rail</label>
		</options>
	</mapengine>
	<crs>EPSG:28355</crs>
	<scales>
		<scale>500</scale>
		<scale>1000</scale>
		<scale>2000</scale>
		<scale>4000</scale>
		<scale>8000</scale>
		<scale>16000</scale>
		<scale>32000</scale>
		<scale>64000</scale>
		<scale>125000</scale>
		<scale>250000</scale>
	</scales>
	<extents>
		<initial crs="EPSG:28355" minx="327098" miny="5811358" maxx="351971" maxy="5827675"/>
		<full crs="EPSG:28355" minx="327098" miny="5811358" maxx="351971" maxy="5827675"/>
		<limit crs="EPSG:28355" minx="320000" miny="5810000" maxx="360000" maxy="5840000"/>
	</extents>
</view>

The current version of the component can be downloaded from here.

The file should be downloaded and copied to the ...\weave\platform\plugins directory, an entry added to the config.ini file in the ...\weave\platform\configuration directory, and then a new view added to the client config.