[QGIS Commit] r9440 - trunk/qgis/src/gui
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Mon Oct 6 13:52:25 EDT 2008
Author: timlinux
Date: 2008-10-06 13:52:25 -0400 (Mon, 06 Oct 2008)
New Revision: 9440
Modified:
trunk/qgis/src/gui/qgsmapcanvas.cpp
trunk/qgis/src/gui/qgsmapcanvas.h
Log:
give better names to some methods
Modified: trunk/qgis/src/gui/qgsmapcanvas.cpp
===================================================================
--- trunk/qgis/src/gui/qgsmapcanvas.cpp 2008-10-06 17:35:46 UTC (rev 9439)
+++ trunk/qgis/src/gui/qgsmapcanvas.cpp 2008-10-06 17:52:25 UTC (rev 9440)
@@ -173,7 +173,7 @@
}
-QgsMapLayer* QgsMapCanvas::getZpos( int index )
+QgsMapLayer* QgsMapCanvas::layer( int index )
{
QStringList& layers = mMapRenderer->layerSet();
if ( index >= 0 && index < ( int ) layers.size() )
@@ -253,7 +253,7 @@
{
// Add check if vector layer when disconnecting from selectionChanged slot
// Ticket #811 - racicot
- QgsMapLayer *currentLayer = getZpos( i );
+ QgsMapLayer *currentLayer = layer( i );
disconnect( currentLayer, SIGNAL( repaintRequested() ), this, SLOT( refresh() ) );
disconnect( currentLayer, SIGNAL( screenUpdateRequested() ), this, SLOT( updateMap() ) );
QgsVectorLayer *isVectLyr = dynamic_cast < QgsVectorLayer * >( currentLayer );
@@ -269,7 +269,7 @@
{
// Add check if vector layer when connecting to selectionChanged slot
// Ticket #811 - racicot
- QgsMapLayer *currentLayer = getZpos( i );
+ QgsMapLayer *currentLayer = layer( i );
connect( currentLayer, SIGNAL( repaintRequested() ), this, SLOT( refresh() ) );
connect( currentLayer, SIGNAL( screenUpdateRequested() ), this, SLOT( updateMap() ) );
QgsVectorLayer *isVectLyr = dynamic_cast < QgsVectorLayer * >( currentLayer );
Modified: trunk/qgis/src/gui/qgsmapcanvas.h
===================================================================
--- trunk/qgis/src/gui/qgsmapcanvas.h 2008-10-06 17:35:46 UTC (rev 9439)
+++ trunk/qgis/src/gui/qgsmapcanvas.h 2008-10-06 17:52:25 UTC (rev 9440)
@@ -172,7 +172,7 @@
void updateFullExtent();
//! return the map layer at position index in the layer stack
- QgsMapLayer *getZpos( int index );
+ QgsMapLayer *layer( int index );
//! return number of layers on the map
int layerCount() const;
More information about the QGIS-commit
mailing list