Community
Participate
Working Groups
Build ID: I20080617-2000 Steps To Reproduce: 1.Create a file and update it but don't save it 2.Delete the file 3.Press OK for confirm delete dialog 4.It reports the unsaved change as found problems with continue option 5.Press continue button 6.Opens a refactoring dialog which says has the problem of unsaved changes More information:
The appearance of the refactoring dialog is rather odd too. Its possible we should prompt, "The file is modified in an editor and there are unsaved changes. Do you wish to proceed with the delete?" only because (1) you may have hit the wrong key and (2) undo of deletion won't get back contents that have never been saved.
This seems to be introduced by the LTK implementation for deleting resources. In Eclipse 3.3.2, here is what happens: - create the file and edit it, but don't save - "Are you sure want to delete foo.txt?" - press Yes - Now we see the "Confirm Delete" dialog with the list of problems including the warning File '/Test/foo.txt' has unsaved changes. - if I press cancel, the delete is canceled, file is still there, etc. - if I press continue, the file is deleted. - during the delete, the file gets saved and the open editor closed. - if I "Undo delete" then the file is restored including the changes I had not manually saved. Here's the same scenario in 3.5 stream - create the file and edit it, but don't save - "Are you sure want to delete foo.txt?" (in 3.5 this includes a preview button courtesy of LTK) - press Yes - Now we see the "Confirm Delete" dialog with the list of problems including the warning File '/Test/foo.txt' has unsaved changes. - if I press cancel, the delete is canceled, file is still there, etc. - if I press continue, I get the refactoring dialog that says "The operation cannot be performed due to the following problem:" Test/foo.txt has unsaved changes. So I think this problem belongs to the LTK participant in resource delete.
Created attachment 120312 [details] Fix
Fixed in HEAD.
*** Bug 210200 has been marked as a duplicate of this bug. ***