Community
Participate
Working Groups
Build 20020612 (F3) When deleting a _project_, the user is prompted to save or delete the underlying resources; however, when deleting a source folder within a project the underlying resources are always deleted -- I had expected to be prompted.
The reason why we prompt for projects is that they can lie outside the workspace (not using default location when creating the project). Source folders always lie inside the workspace therefore we only ask if you want to delete the element.
Not sure what you mean by "projects can lie outside the workspace". It's ok to mark this as a wontfix, but I entered it as a usability issue (since I guessed the behaviour wrongly and lost data). Maybe a different term is appropriate for deleting from the workspace rather than deleting the resource (c.f. the old notion of closing a project).
The difference is as follows: - source folders are always "owned" by a project. That means on a file system the source folder is always a subfolder of the folder representing the project. - this is different for projects. Assume your workspace is at c:\workspace You can create a project Test inside that workspace (e.g. c:\workspace\Test) or as a project that references and already existing folder outside the c:\workspace (for exmaple M:\code\junit). This can be controlled by the Project content option in the new project wizard. If you now delete a project the user must have the possibility to either delete the reference to that project without actually deleting its content since it can be external. Since we don't have meta information about source folders and a source folder is always hosted inside a projects folder we don't offer the same functionality for source folders. The workbench does the same. I hope this makes it clearer.
this is an enhancement really i see 2 possible courses of action here: 1. remove the folder from the classpath (doable) 2. hide the folder (not doable without additional platform support)
Dirk, I didn't really understand your explanation what the difference is (what, if I create a project with a non-default location, i.e. not below "~/workspace/", and then create sources within that project location? does that could as "outside the workspace" or within?) nor do I think that you should have to explain it in the first place. We are talking about deletion of source files, which may contain lots of man hours of work. What you describe cannot be guessed, or at least people can easily guess wrong, so you have to make the UI in a way that the user is totally aware what is about to happen. Compare bug 28995 (the same or similar iissue, I don't know).
In 3.2 you get conformation dialogs for all kin of removals (folders/files) To just remove a source folder from the build path we have a menu entry in the Build Path submenu.