[mapguide-trac] #1873: Expose an boolean value to create the map extent on adding the first layer

MapGuide Open Source trac_mapguide at osgeo.org
Tue Nov 29 08:06:53 EST 2011


#1873: Expose an boolean value to create the map extent on adding the first layer
---------------------------+------------------------------------------------
   Reporter:  gBecker      |       Owner:             
       Type:  enhancement  |      Status:  new        
   Priority:  low          |   Milestone:  Maestro-4.0
  Component:  General      |     Version:  2.1.0      
   Severity:  trivial      |    Keywords:             
External_id:               |  
---------------------------+------------------------------------------------
 my application allows it to make a new MapDefinition from the current
 RuntimeMap. When trying to iterate over the RuntimeMapLayerCollection to
 create the IMapLayer

     mapDef.AddLayer(rtLayer.Group, rtLayer.Name,
 rtLayer.LayerDefinitionID);

 an error occurs on layers that have a FeatureSource that refrence a
 DataStore with no objects (empty SDF in SessionRepository for redlining).

 Comment by Jackie in UserGroup:

 When you add a layer to the Map Definition, if it is the first layer to be
 added, Maestro tries to be smart and grabs the extents of that layer and
 sets the extents of the Map Definition to match.

 This obviously naively assumes the first layer you add has no issues and
 can be queried for extents.

 I think what we can do is expose a boolean property which will determine
 whether this behaviour will occur or not. The default value will be false,
 but will be set to true by the Map Definition Editor in Maestro.

-- 
Ticket URL: <http://trac.osgeo.org/mapguide/ticket/1873>
MapGuide Open Source <http://mapguide.osgeo.org/>
MapGuide Open Source Internals


More information about the mapguide-trac mailing list