Skip to content

Commit abdc1b0

Browse files
author
jef
committedDec 11, 2009
fix #2266
git-svn-id: http://svn.osgeo.org/qgis/trunk@12411 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 97b6298 commit abdc1b0

File tree

1 file changed

+14
-11
lines changed

1 file changed

+14
-11
lines changed
 

‎src/app/qgsmaptooladdisland.cpp

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,16 @@ void QgsMapToolAddIsland::canvasReleaseEvent( QMouseEvent * e )
4040

4141
if ( !vlayer )
4242
{
43-
QMessageBox::information( 0, tr( "Not a vector layer" ),
43+
QMessageBox::information( 0,
44+
tr( "Not a vector layer" ),
4445
tr( "The current layer is not a vector layer" ) );
4546
return;
4647
}
4748

4849
if ( !vlayer->isEditable() )
4950
{
50-
QMessageBox::information( 0, tr( "Layer not editable" ),
51+
QMessageBox::information( 0,
52+
tr( "Layer not editable" ),
5153
tr( "Cannot edit the vector layer. To make it editable, go to the file item "
5254
"of the layer, right click and check 'Allow Editing'." ) );
5355
return;
@@ -58,11 +60,11 @@ void QgsMapToolAddIsland::canvasReleaseEvent( QMouseEvent * e )
5860
QString selectionErrorMsg;
5961
if ( nSelectedFeatures < 1 )
6062
{
61-
selectionErrorMsg = "No feature selected. Please select a feature with the selection tool or in the attribute table";
63+
selectionErrorMsg = tr( "No feature selected. Please select a feature with the selection tool or in the attribute table" );
6264
}
6365
else if ( nSelectedFeatures > 1 )
6466
{
65-
selectionErrorMsg = "Several features are selected. Please select only one feature to which an island should be added.";
67+
selectionErrorMsg = tr( "Several features are selected. Please select only one feature to which an island should be added." );
6668
}
6769

6870
if ( !selectionErrorMsg.isEmpty() )
@@ -84,7 +86,8 @@ void QgsMapToolAddIsland::canvasReleaseEvent( QMouseEvent * e )
8486
else if ( error == 2 )
8587
{
8688
//problem with coordinate transformation
87-
QMessageBox::information( 0, tr( "Coordinate transform error" ),
89+
QMessageBox::information( 0,
90+
tr( "Coordinate transform error" ),
8891
tr( "Cannot transform the point to the layers coordinate system" ) );
8992
return;
9093
}
@@ -110,27 +113,27 @@ void QgsMapToolAddIsland::canvasReleaseEvent( QMouseEvent * e )
110113
{
111114
if ( errorCode == 1 )
112115
{
113-
errorMessage = "Selected feature is not a multipolygon";
116+
errorMessage = tr( "Selected feature is not a multipolygon" );
114117
}
115118
else if ( errorCode == 2 )
116119
{
117-
errorMessage = "New ring is not a valid geometry";
120+
errorMessage = tr( "New ring is not a valid geometry" );
118121
}
119122
else if ( errorCode == 3 )
120123
{
121-
errorMessage = "New polygon ring not disjoint with existing polygons";
124+
errorMessage = tr( "New polygon ring not disjoint with existing polygons" );
122125
}
123126
else if ( errorCode == 4 )
124127
{
125-
errorMessage = "No feature selected. Please select a feature with the selection tool or in the attribute table";
128+
errorMessage = tr( "No feature selected. Please select a feature with the selection tool or in the attribute table" );
126129
}
127130
else if ( errorCode == 5 )
128131
{
129-
errorMessage = "Several features are selected. Please select only one feature to which an island should be added.";
132+
errorMessage = tr( "Several features are selected. Please select only one feature to which an island should be added." );
130133
}
131134
else if ( errorCode == 6 )
132135
{
133-
errorMessage = "Selected geometry could not be found";
136+
errorMessage = tr( "Selected geometry could not be found" );
134137
}
135138
QMessageBox::critical( 0, tr( "Error, could not add island" ), errorMessage );
136139
}

0 commit comments

Comments
 (0)