File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ GraticuleCreator::~GraticuleCreator()
50
50
{
51
51
}
52
52
53
- // TODO: check for rediculous intervals!
53
+ // TODO: check for ridiculous intervals!
54
54
void GraticuleCreator::generatePointGraticule (
55
55
double theXInterval,
56
56
double theYInterval,
@@ -68,6 +68,10 @@ void GraticuleCreator::generatePointGraticule(
68
68
mFields ,
69
69
QGis::WKBPoint,
70
70
&mCRS );
71
+
72
+ if ( theXInterval==0.0 || theYInterval==0.0 )
73
+ return ;
74
+
71
75
//
72
76
// Order our loop so that it goes from smallest to biggest
73
77
//
Original file line number Diff line number Diff line change @@ -56,6 +56,14 @@ void QgsGridMakerPluginGui::on_buttonBox_accepted()
56
56
57
57
double myXInterval = leXInterval->text ().toDouble ();
58
58
double myYInterval = leYInterval->text ().toDouble ();
59
+
60
+ if ( myXInterval==0.0 || myYInterval==0.0 )
61
+ {
62
+ QMessageBox::warning ( 0 , tr ( " QGIS - Grid Maker" ),
63
+ QString ( tr ( " Please enter intervals before pressing OK!" ) ) );
64
+ return ;
65
+ }
66
+
59
67
double myXOrigin = leXLowerLeft->text ().toDouble ();
60
68
double myYOrigin = leYLowerLeft->text ().toDouble ();
61
69
double myEndPointX = leXUpperRight->text ().toDouble ();
You can’t perform that action at this time.
0 commit comments