Skip to content
Permalink
Browse files
indentation update
  • Loading branch information
jef-n committed Apr 4, 2012
1 parent 8784981 commit 0353514182b4c806e1ef2dd670ec5781468d87df
@@ -284,7 +284,7 @@ void QgsLegend::removeGroup( int groupIndex )
void QgsLegend::removeLayers( QStringList theLayers )
{
QgsDebugMsg( "Entering." );
foreach (const QString &myId, theLayers)
foreach( const QString &myId, theLayers )
{
bool invLayerRemoved = false;

@@ -322,7 +322,7 @@ void QgsLegend::removeLayer( QString theLayer )
{
QStringList myList;
myList << theLayer;
removeLayers(myList);
removeLayers( myList );
}

void QgsLegend::mousePressEvent( QMouseEvent * e )
@@ -875,9 +875,9 @@ void QgsLegend::addLayers( QList<QgsMapLayer *> theLayerList )
if ( layers().count() > 0 ) myFirstLayerFlag = true;

//iteratively add the layers to the canvas
for (int i = 0; i < theLayerList.size(); ++i)
for ( int i = 0; i < theLayerList.size(); ++i )
{
QgsMapLayer * layer = theLayerList.at(i);
QgsMapLayer * layer = theLayerList.at( i );
QgsLegendLayer* llayer = new QgsLegendLayer( layer );
if ( !QgsProject::instance()->layerIsEmbedded( layer->id() ).isEmpty() )
{
@@ -928,11 +928,11 @@ void QgsLegend::addLayers( QList<QgsMapLayer *> theLayerList )

updateMapCanvasLayerSet();
emit itemAdded( indexFromItem( llayer ) );
}
}
// first layer?
if ( myFirstLayerFlag )
{
QgsMapLayer * myFirstLayer = theLayerList.at(0);
QgsMapLayer * myFirstLayer = theLayerList.at( 0 );
if ( !mMapCanvas->mapRenderer()->hasCrsTransformEnabled() )
mMapCanvas->mapRenderer()->setDestinationCrs( myFirstLayer->crs() );
mMapCanvas->zoomToFullExtent();
@@ -1173,7 +1173,7 @@ void QgsLegend::removeGroup( QgsLegendGroup *lg )

if ( cl )
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << cl->layer()->id() );
QStringList() << cl->layer()->id() );
else if ( cg )
removeGroup( cg );

@@ -2422,7 +2422,7 @@ void QgsLegend::removeSelectedLayers()
if ( ll && ll->layer() )
{
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << ll->layer()->id() );
QStringList() << ll->layer()->id() );
continue;
}
}
@@ -246,7 +246,7 @@ bool QgsBrowser::layerClicked( QgsLayerItem *item )
QgsDebugMsg( "Layer created" );

QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mLayer );
QList<QgsMapLayer *>() << mLayer );

return true;
}
@@ -101,7 +101,7 @@ bool QgsPluginLayerRegistry::removePluginLayerType( QString typeName )
if ( pl->pluginLayerType() == typeName )
{
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << layer->id() );
QStringList() << layer->id() );
}
}
}
@@ -1428,7 +1428,7 @@ QStringList QgsWMSServer::layerSet( const QStringList &layersList,
{
layerKeys.push_front( theMapLayer->id() );
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << theMapLayer, false );
QList<QgsMapLayer *>() << theMapLayer, false );
}
else
{
@@ -147,7 +147,7 @@ QgsGeorefPluginGui::~QgsGeorefPluginGui()
if ( mLayer )
{
QgsMapLayerRegistry::instance()->removeMapLayers(
(QStringList() << mLayer->id()), false );
( QStringList() << mLayer->id() ), false );
}

delete mToolZoomIn;
@@ -253,7 +253,7 @@ void QgsGeorefPluginGui::openRaster()
//delete any old rasterlayers
if ( mLayer )
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << mLayer->id(), false );
QStringList() << mLayer->id(), false );

// Add raster
addRaster( mRasterFileName );
@@ -1042,7 +1042,7 @@ void QgsGeorefPluginGui::addRaster( QString file )

// so layer is not added to legend
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mLayer, false );
QList<QgsMapLayer *>() << mLayer, false );

// add layer to map canvas
QList<QgsMapCanvasLayer> layers;
@@ -183,7 +183,7 @@ void QgsOfflineEditing::synchronize( QgsLegendInterface* legendInterface )

// register this layer with the central layers registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << remoteLayer, true );
QList<QgsMapLayer *>() << remoteLayer, true );

// apply layer edit log
QString qgisLayerId = layer->id();
@@ -235,7 +235,7 @@ void QgsOfflineEditing::synchronize( QgsLegendInterface* legendInterface )

// remove offline layer
QgsMapLayerRegistry::instance()->removeMapLayers(
(QStringList() << qgisLayerId), true );
( QStringList() << qgisLayerId ), true );

// disable offline project
QString projectTitle = QgsProject::instance()->title();
@@ -498,7 +498,7 @@ void QgsOfflineEditing::copyVectorLayer( QgsVectorLayer* layer, sqlite3* db, con

// register this layer with the central layers registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << newLayer );
QList<QgsMapLayer *>() << newLayer );

if ( hasLabels )
{
@@ -571,7 +571,7 @@ void QgsOfflineEditing::copyVectorLayer( QgsVectorLayer* layer, sqlite3* db, con

// remove remote layer
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << layer->id() );
QStringList() << layer->id() );
}
}
}
@@ -299,7 +299,7 @@ bool QgsSpatialQueryDialog::addLayerSubset( QString name, QString subset )
return false;
}
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << addLyr );
QList<QgsMapLayer *>() << addLyr );
return true;
} // bool QgsSpatialQueryDialog::addLayerSubset( QString name, QString subset )

@@ -167,7 +167,7 @@ void TestQgsMapRenderer::initTestCase()
myPolyFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpPolysLayer );
QList<QgsMapLayer *>() << mpPolysLayer );
// add the test layer to the maprender
mpMapRenderer = new QgsMapRenderer();
QStringList myLayers;
@@ -91,9 +91,9 @@ void TestQgsRasterLayer::initTestCase()
myLandsatRasterFileInfo.completeBaseName() );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpRasterLayer );
QList<QgsMapLayer *>() << mpRasterLayer );
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpLandsatRasterLayer );
QList<QgsMapLayer *>() << mpLandsatRasterLayer );
// add the test layer to the maprender
mpMapRenderer = new QgsMapRenderer();
QStringList myLayers;
@@ -240,9 +240,9 @@ void TestQgsRasterLayer::registry()
myRasterFileInfo.completeBaseName() );

QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mypLayer, false );
QList<QgsMapLayer *>() << mypLayer, false );
QgsMapLayerRegistry::instance()->removeMapLayers(
QStringList() << mypLayer->id() );
QStringList() << mypLayer->id() );
//cleanup
//delete mypLayer;
}
@@ -91,7 +91,7 @@ void TestQgsRenderers::initTestCase()
myPointFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpPointsLayer );
QList<QgsMapLayer *>() << mpPointsLayer );

//
//create a poly layer that will be used in all tests...
@@ -102,7 +102,7 @@ void TestQgsRenderers::initTestCase()
myPolyFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpPolysLayer );
QList<QgsMapLayer *>() << mpPolysLayer );


//
@@ -114,7 +114,7 @@ void TestQgsRenderers::initTestCase()
myLineFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpLinesLayer );
QList<QgsMapLayer *>() << mpLinesLayer );
//
// We only need maprender instead of mapcanvas
// since maprender does not require a qui
@@ -82,7 +82,7 @@ class TestQgsVectorLayer: public QObject
myDbfFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpNonSpatialLayer );
QList<QgsMapLayer *>() << mpNonSpatialLayer );
//
//create a point layer that will be used in all tests...
//
@@ -92,7 +92,7 @@ class TestQgsVectorLayer: public QObject
myPointFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpPointsLayer );
QList<QgsMapLayer *>() << mpPointsLayer );

//
//create a poly layer that will be used in all tests...
@@ -103,7 +103,7 @@ class TestQgsVectorLayer: public QObject
myPolyFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpPolysLayer );
QList<QgsMapLayer *>() << mpPolysLayer );


//
@@ -115,7 +115,7 @@ class TestQgsVectorLayer: public QObject
myLineFileInfo.completeBaseName(), "ogr" );
// Register the layer with the registry
QgsMapLayerRegistry::instance()->addMapLayers(
QList<QgsMapLayer *>() << mpLinesLayer );
QList<QgsMapLayer *>() << mpLinesLayer );
//
// We only need maprender instead of mapcanvas
// since maprender does not require a qui

0 comments on commit 0353514

Please sign in to comment.