Skip to content

Commit

Permalink
Added internationalization string wrapping (tr) patch from lubaby
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@6336 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
gsherman committed Dec 29, 2006
1 parent 8d2717c commit 0f847d4
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/plugins/grass/qgsgrassselect.cpp
Expand Up @@ -65,29 +65,29 @@ QgsGrassSelect::QgsGrassSelect(int type):QgsGrassSelectBase()
switch ( type )
{
case QgsGrassSelect::VECTOR:
setCaption ( "Select GRASS Vector Layer" );
setCaption ( tr("Select GRASS Vector Layer") );
break;

case QgsGrassSelect::RASTER:
/* Remove layer combo box */
Layer->hide();
elayer->hide();
setCaption ( "Select GRASS Raster Layer" );
setCaption ( tr("Select GRASS Raster Layer") );
break;

case QgsGrassSelect::MAPCALC:
/* Remove layer combo box */
Layer->hide();
elayer->hide();
setCaption ( "Select GRASS mapcalc schema" );
setCaption ( tr("Select GRASS mapcalc schema") );
break;

case QgsGrassSelect::MAPSET:
Layer->hide();
elayer->hide();
MapName->hide();
emap->hide();
setCaption ( "Select GRASS Mapset" );
setCaption ( tr("Select GRASS Mapset") );
break;
}

Expand Down Expand Up @@ -404,7 +404,7 @@ QStringList QgsGrassSelect::vectorLayers ( QString gisdbase,

if ( level < 2 ) {
std::cerr << "Cannot open vector on level 2" << std::endl;
QMessageBox::warning( 0, "Warning", "Cannot open vector on level 2 (topology not available)." );
QMessageBox::warning( 0, tr("Warning"), tr("Cannot open vector on level 2 (topology not available).") );
return list;
}

Expand Down Expand Up @@ -462,7 +462,7 @@ void QgsGrassSelect::on_GisdbaseBrowse_clicked()
{

QString Gisdbase = QFileDialog::getExistingDirectory( this,
"Choose existing GISDBASE", egisdbase->text() );
tr("Choose existing GISDBASE"), egisdbase->text() );

if ( !Gisdbase.isNull() )
{
Expand All @@ -478,8 +478,8 @@ void QgsGrassSelect::on_ok_clicked()
lastGisdbase = QString( gisdbase );

if ( elocation->count() == 0 ) {
QString msg = "Wrong GISDBASE, no locations available.";
QMessageBox::warning(this, "Wrong GISDBASE", msg);
QString msg = tr("Wrong GISDBASE, no locations available.");
QMessageBox::warning(this, tr("Wrong GISDBASE"), msg);
return;
}

Expand All @@ -496,17 +496,17 @@ void QgsGrassSelect::on_ok_clicked()
map = emap->currentText().stripWhiteSpace();

if ( type != QgsGrassSelect::MAPSET && map.isEmpty() ) {
QString msg = "Select a map.";
QMessageBox::warning(0, "No map", msg);
QString msg = tr("Select a map.");
QMessageBox::warning(0, tr("No map"), msg);
return;
}

if ( type == QgsGrassSelect::VECTOR )
{
if ( elayer->count() == 0 )
{
QMessageBox::warning(0, "No layer",
"No layers available in this map");
QMessageBox::warning(0, tr("No layer"),
tr("No layers available in this map"));
return;
}
lastVectorMap = map;
Expand Down

0 comments on commit 0f847d4

Please sign in to comment.