Re: onMenuCmd Vs. runMenuCmd

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Re: onMenuCmd Vs. runMenuCmd

Michael Barton

I just added RunMenuCmd and differentiated it from OnMenuCmd (the original
method) yesterday.

The difference is that OnMenuCmd expects a GRASS command WITHOUT arguments
and passes it to the parser to open a properties dialog.

RunMenuCmd expects a GRASS command WITH arguments (e.g., g.region -p) and
sends it on directly to the command parser in, WITHOUT opening
a properties dialog. There are a number of menu entries that need this kind
of treatment. This seemed the simplest way to deal with them within the
current structure.


On 6/8/07 10:22 AM, "Yann" <[hidden email]> wrote:

> Hello Michael,
> Could make a brief description on when to use "onMenuCmd" and "runMenuCmd"?
> Is there a change happening on this these days, or that happened some time
> back? How could we know if our new modules will run from them?
> thank you,
> Yann

Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics and Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671

grassgui mailing list
[hidden email]