| Summary: | [Undo] [IDE] - No prompt when deleting read only file via undo/redo | ||
|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | John Arthorne <john.arthorne> |
| Component: | UI | Assignee: | Susan McCourt <susan> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | susan |
| Version: | 3.3 | ||
| Target Milestone: | 3.3 M4 | ||
| Hardware: | PC | ||
| OS: | Windows Vista | ||
| Whiteboard: | |||
|
Description
John Arthorne
In the original version, I had the operations check read-only status and prompt. This proved quite annoying when the original operation was confirmed by the user. For example... - delete a read-only file, you are prompted. - undo the delete - redo the delete, you are prompted again. In that case, I decided that once prompted on the original operation, it was redundant to keep asking. So I let the client action do the prompting and the operation do nothing. But your case is different...the state changed after the original operation, so the check is valid. To be smarter here, the operation could provide the initial prompting (instead of the client) and then only prompt again if the read only state of its file changes. Fixed in HEAD >20061108. The operation now checks read-only status on all deletes, including: - undo of a create - execute/redo of a delete - undo of a copy Removed read-only status checking from the DeleteResourceAction. I did not add any logic to limit prompting on redo only if the read only state was added since the original operation. That would have required changing the life-cycle of the resource description snapshots, and I don't think it's worth it. The behavior now is that if the user refuses to delete read only file(s) on an undo or redo, the operation is either performed on the non-read only files, or if the user refused to delete any of the files, then the operation is cancelled and the undo/redo remains in the history (and will prompt again when the user tries it). Verified with given scenarios and with deletion of a file that was read only from the beginning. (Can't be verified in an automated test since it involves prompting.) verified on M5, WinXP, with scenario from comment #0 |