#156 closed defect (fixed)
closing an active editor doesn't work (buggy or confusing PGRetargetableAction.setBusy())
Reported by: | alex heneveld | Owned by: | David Aspinall |
---|---|---|---|
Priority: | blocker | Milestone: | |
Component: | 1:pg-eclipse | Keywords: | |
Cc: |
Description (last modified by )
if i close an active editor, the GotoAction? throws an NPE when trying to undo-all the proof script. thereafter the user cannot activate any script (even re-opening the same file) until the prover is restarted.
see comments in PGRetargetableAction.setBusy(): it looks like this call does not do what it is supposed to if the document is set manually (as it is from ActivateAction?.closeDownScript).
as a larger issue, we need to consider the different cases of closing (and re-opening) a script:
(a) if the script is fully processed, the user probably wants to keep it in the prover's memory (i.e. don't retract); however they do need a way to retract it later, probably re-opening the script should "remember" it is fully processed. (not sure what we do currently)
(b) if the script is partially processed, it is probably okay to undo all (which we currently do, modulo fixing the above bug). however it would be nicer, i think, to give the user the option to (a) discard (undo all); (b) finish processing; (c) cancel. (and maybe option to "do nothing", leave partially processed, and restoring it if they open the file later.) we used to do this, but it is commented out (in ActivateAction?). possibly because we were not getting reliably informed about shutdown events and so were pointlessly prompting the user on shutdown...)
Attachments (1)
Change History (5)
comment:1 Changed 16 years ago by
Description: | modified (diff) |
---|---|
Owner: | changed from David Aspinall to Graham Dutton |
Status: | new → assigned |
comment:2 Changed 16 years ago by
Description: | modified (diff) |
---|---|
Owner: | changed from Graham Dutton to David Aspinall |
Priority: | major → blocker |
comment:3 Changed 16 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Solved by adding session manager argument to the non-retargetable constructors used for temporary SendAll
and UndoAll
actions.
I'm having a quick look at this. Note (a): we do remember processed scripts, see
ControlledDocuments
class.I've committed some possible improvements and reinstated the dialog (one reason to disable it is the lack of a "remember my decision"!). But currently still buggy --- ad hoc actions without editors still aren't managed well, maybe we need a document-based action with retargetable wrapper.