[kepler-dev] [Bug 2246] - TOOLBAR: status on opening workflows and blank frames
bugzilla-daemon at ecoinformatics.org
Thu Apr 13 14:24:22 PDT 2006
cxh at eecs.berkeley.edu changed:
What |Removed |Added
------- Comment #23 from cxh at eecs.berkeley.edu 2006-04-13 14:24 -------
I took another look at this bug. In many ways, we could probably
close this, it falls under the newer bug
"enable/disable menu items and toolbar items as appropriate"
I think this bug started out as one using the new button images and has
slowly transmogrified. If someone wants to close this, I'm all for it.
I've lowered the priority slightly on this one, since it does not
prevent someone from working or lose data. I'm tempted to make it an
enhancement, but it is a borderline case of a bug.
The bug here is that when we open a blank frame, Laura would like none
of the run/start/stop buttons to be enabled until the user
starts creating amodel.
As a short term hack, I adjusted the error message so that if the user
does hit Run on an empty model, the exception says:
"Cannot preinitialize an empty model, please add actors and a director."
To really fix this bug, we should probably add another state, called
RUNNABLE, which means that the model contains one actor.
(Note that if there is no director in a model, then the default Director
is chosen, which fires the actors in the order they were placed in the model.)
Then, when the user drags an actor in, we could set the manager state
to RUNNABLE and the UI Run button would be enabled.
Another hack would be to try and modify
RunnableGraphController.managerStateChanged(), and put the logic of checking
if the model has an actors there. However, that code is only called when
the manager state changes, so it would never see that the model has actors
so the Run button would never be enabled.
I do think that the current functionality we have for opening a preexisting
model is correct. The model is in the stopped state, so the stop button
should be highlighted. Some model viewers, such as the MoMLApplet can
auto start models, and MoMLApplication can take a -run argument which
automatically runs the models. Thus, having the stop button highlighted
makes sense here if the model is runnable.
More information about the Kepler-dev