Since Map Suite 8.0, The LayerOverlay.IsBaseOverlay by
default would be false, while in 7.* it is true.
We did this change to make the code more straightforward for
simple scenarios. Take this for example: say I want to add a shape file on top of the
WorldMapKitOverlay and display them on the map, in 7.*, the following code are needed:
WorldMapKitWmsWebOverlay worldMapKitOverlay =
new
WorldMapKitWmsWebOverlay();
Map1.CustomOverlays.Add(worldMapKitOverlay);
LayerOverlay layerOverlay =new
LayerOverlay();
layerOverlay.Layers.Add(shapeFileLayer);
// we need to have the following code, otherwise the layerOverlay would be BaseOverlay, which would conflict with the WorldMapKitOverlay as only one overlay can be displayed one time.
layerOverlay.IsBaseOverlay =
false
;
Map1.CustomOverlays.Add(layerOverlay);
In 8.0, for the same thing, the code would be like this:
WorldMapKitWmsWebOverlay worldMapKitOverlay =
new
WorldMapKitWmsWebOverlay();
Map1.CustomOverlays.Add(worldMapKitOverlay);
LayerOverlay layerOverlay =
new
LayerOverlay();
layerOverlay.Layers.Add(shapeFileLayer);
Map1.CustomOverlays.Add(layerOverlay);
It would be more straightforward for the new users. It would change the current map appearance though if you are using the
LayerOverlay() or LayerOverlay(string id) constructors without setting IsBaseOverlay property explicitly later.
It would not affect you at all if you are using the following
constructor
LayerOverlay(
string
id,
bool
isBaseOverlay, TileType tileType)
Or explicitly set the LayerOverlay.IsBaseOverlay
Sorry for the inconvenience.