Explorar o código

use G_define_standard_option; fixed input parm name

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@33823 15284696-431f-4ddb-bdfa-cd5b030d7da7
Markus Neteler %!s(int64=17) %!d(string=hai) anos
pai
achega
5b1c5bd62e
Modificáronse 1 ficheiros con 3 adicións e 11 borrados
  1. 3 11
      raster/r.volume/main.c

+ 3 - 11
raster/r.volume/main.c

@@ -60,27 +60,19 @@ int main(int argc, char *argv[])
 	  "and (optionally) produces a GRASS vector points map "
 	  "and (optionally) produces a GRASS vector points map "
 	  "containing the calculated centroids of these clumps.");
 	  "containing the calculated centroids of these clumps.");
 
 
-    opt1 = G_define_option();
-    opt1->key = "data";
-    opt1->type = TYPE_STRING;
-    opt1->required = YES;
-    opt1->gisprompt = "old,cell,raster";
+    opt1 = G_define_standard_option(G_OPT_R_INPUT);
     opt1->description =
     opt1->description =
 	_("Existing raster map representing data that will be summed within clumps");
 	_("Existing raster map representing data that will be summed within clumps");
 
 
-    opt2 = G_define_option();
+    opt2 = G_define_standard_option(G_OPT_R_INPUT);
     opt2->key = "clump";
     opt2->key = "clump";
-    opt2->type = TYPE_STRING;
     opt2->required = NO;
     opt2->required = NO;
-    opt2->gisprompt = "old,cell,raster";
     opt2->description =
     opt2->description =
 	_("Existing raster map, preferably the output of r.clump");
 	_("Existing raster map, preferably the output of r.clump");
 
 
-    opt3 = G_define_option();
+    opt3 = G_define_standard_option(G_OPT_V_OUTPUT);
     opt3->key = "centroids";
     opt3->key = "centroids";
-    opt3->type = TYPE_STRING;
     opt3->required = NO;
     opt3->required = NO;
-    opt3->gisprompt = "new,vector,vector";
     opt3->description = _("Vector points map to contain clump centroids");
     opt3->description = _("Vector points map to contain clump centroids");
 
 
     flag1 = G_define_flag();
     flag1 = G_define_flag();