[Qgis-developer] Syntax for using QList<QgsMapLayer *> signal in python

Tim Sutton lists at linfiniti.com
Thu Apr 19 05:09:53 EDT 2012


Hi All

Does anyone know the appropriate way to connect to the new
QgsMapLayerRegistry signal I added in python:

void layersAdded( QList<QgsMapLayer *> theMapLayers );

I tried:

            QtCore.QObject.connect(QgsMapLayerRegistry.instance(),
                    QtCore.SIGNAL('layersWillBeRemoved(QList<QgsMapLayer*>)'),
                    self.getLayers)

But that doesnt seem to be hitting my slot.

Thanks

tim

-- 
Tim Sutton - QGIS Project Steering Committee Member (Release  Manager)
==============================================
Please do not email me off-list with technical
support questions. Using the lists will gain
more exposure for your issues and the knowledge
surrounding your issue will be shared with all.

Visit http://linfiniti.com to find out about:
 * QGIS programming and support services
 * Mapserver and PostGIS based hosting plans
 * FOSS Consulting Services
Skype: timlinux
Irc: timlinux on #qgis at freenode.net
==============================================


More information about the Qgis-developer mailing list