|
From: Joe E. <jen...@fl...> - 2005-07-25 17:30:15
|
Jeff Hobbs wrote:
> > Also, in the current implementation the command can use
> > 'return -code break' or 'return -code continue' to prevent
> > the dialog from being dismissed. I left this undocumented
> > since I'm not sure if it's a good idea; it seems like a bit
> > of a hairball. Opinions?
>
> +1, although I might opt to separate what break and continue
> mean.
Agreed. I was thinking of something along these lines
for -command return code interpretations:
TCL_OK --
Default behavior -- dismiss the dialog if '-persistent false',
leave it up if '-persistent true'.
TCL_BREAK --
Always dismiss the dialog (overriding '-persistent true')
TCL_CONTINUE --
Always leave the dialog up (overriding '-persistent false')
TCL_RETURN --
(same as TCL_OK?)
TCL_ERROR --
Return the error result to the caller (normally
the event loop, which will eventually call bgerror).
Not sure what else should happen -- probably ought
to release the grab if '-modal true' was set.
Other --
Return the completion code/result/other return options
to to the caller.
--Joe English
jen...@fl...
|