Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 13702 - Folder icon shows as a java package when empty [package explorer]
Summary: Folder icon shows as a java package when empty [package explorer]
Status: RESOLVED WONTFIX
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Erich Gamma CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-12 15:19 EDT by Richard Bone CLA
Modified: 2002-07-24 08:46 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Bone CLA 2002-04-12 15:19:31 EDT
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.
Comment 1 Olivier Thomann CLA 2002-04-12 15:53:57 EDT
This is a problem in JUI.
The method seems to 
be:
org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider.getBaseImageDescriptor(IJavaElement, 
int).
Move to JUI.
Comment 2 Erich Gamma CLA 2002-04-13 08:39:16 EDT
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.
Comment 3 Richard Bone CLA 2002-04-15 14:18:07 EDT
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.
Comment 4 Erich Gamma CLA 2002-04-23 06:31:10 EDT
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.
Comment 5 Dirk Baeumer CLA 2002-07-23 12:36:24 EDT
[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.
Comment 6 Dirk Baeumer CLA 2002-07-23 12:37:04 EDT
This will not be fixed for 2.1