mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
indentation update
This commit is contained in:
parent
0c0293e9b8
commit
e225385aaa
@ -96,8 +96,8 @@ QSize QgsWelcomePageItemDelegate::sizeHint( const QStyleOptionViewItem & option,
|
||||
if ( option.rect.width() < 450 )
|
||||
{
|
||||
width = 450;
|
||||
}
|
||||
else
|
||||
}
|
||||
else
|
||||
{
|
||||
width = option.rect.width();
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ class CORE_EXPORT QgsNetworkAccessManager : public QNetworkAccessManager
|
||||
void requestAboutToBeCreated( QNetworkAccessManager::Operation, const QNetworkRequest &, QIODevice * );
|
||||
void requestCreated( QNetworkReply * );
|
||||
void requestTimedOut( QNetworkReply * );
|
||||
/** Emited when request was sent by request()
|
||||
/** Emitted when request was sent by request()
|
||||
* @param reply request reply
|
||||
* @param sender the object which called request() slot.
|
||||
*/
|
||||
|
@ -300,8 +300,8 @@ QgsGrassModuleStandardOptions::QgsGrassModuleStandardOptions(
|
||||
|
||||
if ( mParams.size() == 0 )
|
||||
{
|
||||
QLabel *label = new QLabel(this);
|
||||
label->setText( tr("This module has no options") );
|
||||
QLabel *label = new QLabel( this );
|
||||
label->setText( tr( "This module has no options" ) );
|
||||
mypSimpleLayout->addWidget( label );
|
||||
}
|
||||
|
||||
|
@ -31,7 +31,7 @@ __revision__ = '$Format:%H$'
|
||||
# AUTHOR(S): Radim Blazek
|
||||
#
|
||||
# PURPOSE: Upgrade all vectors from GRASS 6 to GRASS 7
|
||||
#
|
||||
#
|
||||
# COPYRIGHT: (C) 2015 by Radim Blazek
|
||||
#
|
||||
# This program is free software under the GNU General Public
|
||||
@ -53,20 +53,21 @@ except ImportError:
|
||||
except:
|
||||
raise Exception("Cannot find 'grass' Python module. Python is supported by GRASS from version >= 6.4")
|
||||
|
||||
|
||||
def main():
|
||||
# see https://grasswiki.osgeo.org/wiki/Convert_all_GRASS_6_vector_maps_to_GRASS_7
|
||||
grass.message('Building topology')
|
||||
if grass.run_command('v.build.all') != 0:
|
||||
grass.warning('Cannot build topology')
|
||||
# see https://grasswiki.osgeo.org/wiki/Convert_all_GRASS_6_vector_maps_to_GRASS_7
|
||||
grass.message('Building topology')
|
||||
if grass.run_command('v.build.all') != 0:
|
||||
grass.warning('Cannot build topology')
|
||||
|
||||
grass.message('Creating new DB connection')
|
||||
if grass.run_command('db.connect', flags='d') != 0:
|
||||
grass.warning('Cannot create new DB connection')
|
||||
return
|
||||
grass.message('Creating new DB connection')
|
||||
if grass.run_command('db.connect', flags='d') != 0:
|
||||
grass.warning('Cannot create new DB connection')
|
||||
return
|
||||
|
||||
grass.message('Transfering tables to the new DB')
|
||||
if grass.run_command('v.db.reconnect.all', flags='cd') != 0:
|
||||
grass.warning('Cannot transfer tables')
|
||||
grass.message('Transfering tables to the new DB')
|
||||
if grass.run_command('v.db.reconnect.all', flags='cd') != 0:
|
||||
grass.warning('Cannot transfer tables')
|
||||
|
||||
if __name__ == "__main__":
|
||||
options, flags = grass.parser()
|
||||
|
@ -398,7 +398,7 @@ class GRASS_LIB_EXPORT QgsGrassProvider : public QgsVectorDataProvider
|
||||
|
||||
signals:
|
||||
// TODO: move to QGIS core?
|
||||
// Emited when a fields was added/deleted so that other layers sharing the same layer
|
||||
// Emitted when a fields was added/deleted so that other layers sharing the same layer
|
||||
// may be updated
|
||||
void fieldsChanged();
|
||||
|
||||
|
@ -149,7 +149,7 @@ class GRASS_LIB_EXPORT QgsGrassVectorMap : public QObject
|
||||
/** Close all iterators. Connected to iterators in different threads with Qt::BlockingQueuedConnection */
|
||||
void closeIterators();
|
||||
|
||||
/** Emited when data were reloaded */
|
||||
/** Emitted when data were reloaded */
|
||||
void dataChanged();
|
||||
|
||||
private:
|
||||
|
@ -994,8 +994,8 @@ bool QgsGrassVectorMapLayer::recordExists( int cat, QString &error )
|
||||
|
||||
// DBF driver in GRASS does not support count(*)
|
||||
dbValue value;
|
||||
int nValues = db_select_value(mDriver, mFieldInfo->table, mFieldInfo->key, cat, mFieldInfo->key, &value);
|
||||
if ( nValues == -1)
|
||||
int nValues = db_select_value( mDriver, mFieldInfo->table, mFieldInfo->key, cat, mFieldInfo->key, &value );
|
||||
if ( nValues == -1 )
|
||||
{
|
||||
error = tr( "Cannot select record from table" );
|
||||
return false;
|
||||
|
@ -1072,7 +1072,7 @@ QSet<QString> QgsServerProjectParser::findRestrictedLayers() const
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// wmsLayerRestrictionValues contains LayerIDs
|
||||
if ( mUseLayerIDs )
|
||||
{
|
||||
|
@ -1911,7 +1911,7 @@ int QgsWMSServer::configureMapRender( const QPaintDevice* paintDevice ) const
|
||||
mMapRenderer->addLayerCoordinateTransform( ltIt->first, t.srcAuthId, t.destAuthId, t.srcDatumTransform, t.destDatumTransform );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//then set destinationCrs
|
||||
mMapRenderer->setDestinationCrs( outputCRS );
|
||||
mMapRenderer->setProjectionsEnabled( true );
|
||||
|
@ -447,7 +447,7 @@ void TestQgsSymbolV2::symbolProperties()
|
||||
QgsSymbolLayerV2Utils::symbolProperties( fillSymbol2 ) );
|
||||
|
||||
//modify one of the symbols
|
||||
fillSymbol2->symbolLayer(0)->setColor( QColor( 235, 135, 35 ) );
|
||||
fillSymbol2->symbolLayer( 0 )->setColor( QColor( 235, 135, 35 ) );
|
||||
QVERIFY( QgsSymbolLayerV2Utils::symbolProperties( fillSymbol ) !=
|
||||
QgsSymbolLayerV2Utils::symbolProperties( fillSymbol2 ) );
|
||||
|
||||
|
@ -1257,7 +1257,7 @@ bool TestQgsGrassProvider::compare( QList<QgsFeature> features, QList<QgsFeature
|
||||
|
||||
bool TestQgsGrassProvider::compare( QString uri, QgsGrassObject mapObject, QgsVectorLayer *expectedLayer, bool& ok )
|
||||
{
|
||||
Q_UNUSED(mapObject)
|
||||
Q_UNUSED( mapObject )
|
||||
QList<QgsFeature> expectedFeatures = getFeatures( expectedLayer );
|
||||
|
||||
// read the map using another layer/provider
|
||||
@ -1296,19 +1296,19 @@ bool TestQgsGrassProvider::compare( QString uri, QgsGrassObject mapObject, QgsVe
|
||||
int result = Vect_open_old( map, mapObject.name().toUtf8().data(), mapObject.mapset().toUtf8().data() );
|
||||
|
||||
if ( result == -1 )
|
||||
{
|
||||
QgsGrass::vectDestroyMapStruct( map );
|
||||
throw QgsGrass::Exception( "Cannot open map " + mapObject.name() );
|
||||
}
|
||||
{
|
||||
QgsGrass::vectDestroyMapStruct( map );
|
||||
throw QgsGrass::Exception( "Cannot open map " + mapObject.name() );
|
||||
}
|
||||
|
||||
#if ( GRASS_VERSION_MAJOR == 6 && GRASS_VERSION_MINOR >= 4 ) || GRASS_VERSION_MAJOR > 6
|
||||
Vect_build( map );
|
||||
Vect_build( map );
|
||||
#else
|
||||
Vect_build( map, stderr );
|
||||
Vect_build( map, stderr );
|
||||
#endif
|
||||
//Vect_set_release_support( map );
|
||||
Vect_close( map );
|
||||
QgsGrass::vectDestroyMapStruct( map );
|
||||
//Vect_set_release_support( map );
|
||||
Vect_close( map );
|
||||
QgsGrass::vectDestroyMapStruct( map );
|
||||
}
|
||||
G_CATCH( QgsGrass::Exception &e )
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user