[Mapguide-trac] [mapguide-trac] #2189: MgLayerCollection::Remove returns true even for non-existent layers
MapGuide Open Source
trac_mapguide at osgeo.org
Mon Nov 26 07:39:57 PST 2012
#2189: MgLayerCollection::Remove returns true even for non-existent layers
-----------------------+----------------------------------------------------
Reporter: jng | Owner:
Type: defect | Status: new
Priority: low | Milestone:
Component: General | Version: 2.4.0
Severity: trivial | Keywords:
External_id: |
-----------------------+----------------------------------------------------
If you call Remove() on a MgLayerCollection passing in a layer that
doesn't belong to the collection, true is returned.
This is inconsistent with the behaviour of other collection classes. where
the contract is Remove() returns true if the layer was removed
successfully.
With the MgLayerCollection, it's even worse as it will then detach this
non-existent layer and track it's changes even though it doesn't belong to
the collection
Attached is a patch to fix this behavior
--
Ticket URL: <http://trac.osgeo.org/mapguide/ticket/2189>
MapGuide Open Source <http://mapguide.osgeo.org/>
MapGuide Open Source Internals
More information about the mapguide-trac
mailing list