Skip to content

Commit 45f43c3

Browse files
author
jef
committed
update translation strings
git-svn-id: http://svn.osgeo.org/qgis/trunk@10240 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent bb61177 commit 45f43c3

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

src/app/qgisapp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3751,7 +3751,7 @@ void QgisApp::deleteSelected()
37513751

37523752
//display a warning
37533753
int numberOfDeletedFeatures = vlayer->selectedFeaturesIds().size();
3754-
if(QMessageBox::warning(this, tr("Delete features"), tr("Delete %1 feature(s)?").arg(numberOfDeletedFeatures), QMessageBox::Ok, QMessageBox::Cancel) == QMessageBox::Cancel)
3754+
if ( QMessageBox::warning( this, tr( "Delete features" ), tr( "Delete %n feature(s)?", "number of features to delete", numberOfDeletedFeatures ), QMessageBox::Ok, QMessageBox::Cancel ) == QMessageBox::Cancel )
37553755
{
37563756
return;
37573757
}

src/core/raster/qgsrasterlayer.cpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ QgsRasterLayer::QgsRasterLayer( int dummy,
209209
);
210210
QgsDebugMsg( "(8 arguments) exiting." );
211211

212-
emit statusChanged( "QgsRasterLayer created" );
212+
emit statusChanged( tr( "QgsRasterLayer created" ) );
213213
} // QgsRasterLayer ctor
214214

215215
QgsRasterLayer::~QgsRasterLayer()
@@ -222,7 +222,7 @@ QgsRasterLayer::~QgsRasterLayer()
222222
GDALDereferenceDataset( mGdalBaseDataset );
223223
}
224224

225-
if( mGdalDataset )
225+
if ( mGdalDataset )
226226
{
227227
GDALClose( mGdalDataset );
228228
}
@@ -723,7 +723,7 @@ const QgsRasterBandStats QgsRasterLayer::bandStatistics( int theBandNo )
723723
return myRasterBandStats;
724724
}
725725
// only print message if we are actually gathering the stats
726-
emit statusChanged( QString( "Retrieving stats for " ) + name() );
726+
emit statusChanged( tr( "Retrieving stats for %1" ).arg( name() ) );
727727
qApp->processEvents();
728728
QgsDebugMsg( "stats for band " + QString::number( theBandNo ) );
729729
GDALRasterBandH myGdalBand = GDALGetRasterBand( mGdalDataset, theBandNo );
@@ -737,7 +737,7 @@ const QgsRasterBandStats QgsRasterLayer::bandStatistics( int theBandNo )
737737

738738
myRasterBandStats.elementCount = 0; // because we'll be counting only VALID pixels later
739739

740-
emit statusChanged( QString( "Calculating stats for " ) + name() );
740+
emit statusChanged( tr( "Calculating stats for %1" ).arg( name() ) );
741741
//reset the main app progress bar
742742
emit drawingProgress( 0, 0 );
743743

@@ -1492,7 +1492,7 @@ bool QgsRasterLayer::draw( QgsRenderContext& rendererContext )
14921492
{
14931493
QgsDebugMsg( "Wanting a '" + mProviderKey + "' provider to draw this." );
14941494

1495-
emit statusChanged( QString( "Retrieving using " ) + mProviderKey );
1495+
emit statusChanged( tr( "Retrieving using %1" ).arg( mProviderKey ) );
14961496

14971497
QImage* image =
14981498
mDataProvider->draw(
@@ -1538,13 +1538,13 @@ bool QgsRasterLayer::draw( QgsRenderContext& rendererContext )
15381538
int myWidth = image->width();
15391539
int myHeight = image->height();
15401540
QRgb myRgb;
1541-
for( int myHeightRunner = 0; myHeightRunner < myHeight; myHeightRunner++ )
1541+
for ( int myHeightRunner = 0; myHeightRunner < myHeight; myHeightRunner++ )
15421542
{
1543-
for( int myWidthRunner = 0; myWidthRunner < myWidth; myWidthRunner++ )
1544-
{
1545-
myRgb = image->pixel( myWidthRunner, myHeightRunner );
1546-
image->setPixel( myWidthRunner, myHeightRunner, qRgba( qRed( myRgb ), qGreen( myRgb ), qBlue( myRgb ), mTransparencyLevel ) );
1547-
}
1543+
for ( int myWidthRunner = 0; myWidthRunner < myWidth; myWidthRunner++ )
1544+
{
1545+
myRgb = image->pixel( myWidthRunner, myHeightRunner );
1546+
image->setPixel( myWidthRunner, myHeightRunner, qRgba( qRed( myRgb ), qGreen( myRgb ), qBlue( myRgb ), mTransparencyLevel ) );
1547+
}
15481548
}
15491549

15501550
// Since GDAL's RasterIO can't handle floating point, we have to round to
@@ -3405,7 +3405,7 @@ void QgsRasterLayer::setNoDataValue( double theNoDataValue )
34053405
void QgsRasterLayer::setRasterShaderFunction( QgsRasterShaderFunction* theFunction )
34063406
{
34073407
//Free old shader if it is not a userdefined shader
3408-
if( mColorShadingAlgorithm != QgsRasterLayer::UserDefinedShader && 0 != mRasterShader->rasterShaderFunction() )
3408+
if ( mColorShadingAlgorithm != QgsRasterLayer::UserDefinedShader && 0 != mRasterShader->rasterShaderFunction() )
34093409
{
34103410
delete( mRasterShader->rasterShaderFunction() );
34113411
}

0 commit comments

Comments
 (0)