Skip to content

Commit 6209b6b

Browse files
author
timlinux
committedMar 19, 2008
Cleanup comments and note that layers are deleted when removed from the registry
git-svn-id: http://svn.osgeo.org/qgis/trunk@8253 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 1da19fa commit 6209b6b

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed
 

‎src/core/qgsmaplayerregistry.h

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -67,49 +67,41 @@ class CORE_EXPORT QgsMapLayerRegistry : public QObject
6767
QgsMapLayer * addMapLayer(QgsMapLayer * theMapLayer, bool theEmitSignal = TRUE);
6868

6969
/** Remove a layer from qgis
70-
7170
@note
72-
7371
As a side-effect QgsProject is made dirty.
74-
7572
Any canvases using that layer will need to remove it
76-
7773
theEmitSignal - see addMapLayer()
74+
The layer being removed is deleted as well as the registry
75+
table entry.
7876
*/
7977
void removeMapLayer(QString theLayerId, bool theEmitSignal = TRUE);
8078

8179
/** Remove all registered layers
82-
8380
@note raises removedAll()
84-
8581
As a side-effect QgsProject is made dirty.
86-
82+
@note The layers are deleted as the registry is cleared!
8783
*/
8884
void removeAllMapLayers();
8985

9086
signals:
9187

9288
/** emitted when a layer is removed from the registry
93-
9489
connected to main map canvas and overview map canvas remove()
9590
*/
9691
void layerWillBeRemoved(QString theLayerId);
9792

9893
/** emitted when a layer is added to the registry
99-
10094
connected to main map canvas and overview map canvas addLayer()
10195
*/
10296
void layerWasAdded(QgsMapLayer * theMapLayer);
10397

10498
/** emitted when ALL layers are removed at once
105-
10699
This could have been implemented by iteratively signalling
107100
layerWillBeRemoved() for each layer as it is removed. However, this
108101
generally causes a cascade of effects that are unnecessary if we're
109102
ultimately removing all layers. E.g., removing the legend item
110103
corresponding to the layer. Why bother doing that when you're just going
111104
to clear everything anyway?
112-
113105
*/
114106
void removedAll();
115107

0 commit comments

Comments
 (0)
Please sign in to comment.