This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Build 20040613; j2sdk1.4.2 !!! Steps: - select java file node in the Project view - invoke Add | Enumeration ... - fill items in the Enumeration dialog and confirm it => attached exception is thrown - invoke Add | Enumeration ... - fill items in the Enumeration dialog and confirm it - a new enumeration is added - double click on the enumeration node => attached exception is thrown
Created attachment 15674 [details] Exception
re: Add | Enumeration menu item is presented on j2sdk1.4.2 Presence of the menu item is intentional. We agreed with HIE on this.
The exception is not thrown anymore, but the enum is not added since it should be forbidden for source level 1.4 - it is impossible to add enums via the JMI API when the source level is set to 1.4. This is intentional, since enabling it would require a lot of additional handling which at this point we want to avoid. I talked to Honza about this and the conclusion was that Add Enumeration... and Add Annotation Type... menu items will not be available if the source level is < 1.5. Reassigning to Honza to implement the menu items disabling/removal.
Lowering priority since the exception is no longer thrown, and the code is not corrupted. Just the enum is not added.
Moved to new subcomponent java/javacore.
fixed in /cvs/java/src/org/netbeans/modules/java/ui/nodes/elements/ClassNode.java,v <-- ClassNode.java new revision: 1.6; previous revision: 1.5 /cvs/java/src/org/netbeans/modules/java/ui/nodes/elements/SourceEditSupport.java,v <-- SourceEditSupport.java new revision: 1.6; previous revision: 1.5
Verified