Community
Participate
Working Groups
Description: When creating a folder in a java project, on build 321. The java package icon is used instead of the correct folder icon. The icon is corrected when a txt file, for example, is placed in the folder. If you move the file out of the folder, the icon will again change back to that of a java package. Expected Results: When a folder is created, it is expected that it have the folder icon. Actual Results: The icon is the java package icon, until a file is within it. To reproduce: 1. Create a java project. 2. Create a folder 3. Notice the icon at this point. 4. Create a file inside the folder 5. Watch the icon change for the folder. 6. Move the file to the top-level of the project. 7. The folder icon will change again.
This is a problem in JUI. The method seems to be: org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider.getBaseImageDescriptor(IJavaElement, int). Move to JUI.
This is intentional, we consider an empty folder as a package by default. The rational is that the user used create new package and it would be confusing when the result is a folder. We had the requested behaviour earlier and users have complained.
I'm not sure we're on the same page here. The scenario described in the bug is that the user created a new folder using File>New>Folder and not File>New>Package.
Creating a folder under a package fragment root is the same as creating a package. The UI cannot distinguish this case. We cannot change this for 2.0.
[package explorer] As long as we don't store meta information about "what are folders and what are packages" there is nothing we can do here. And there aren't any plans for Eclipse to add this information since this makes it harder to embed external tools.
This will not be fixed for 2.1