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.
NB 4.2 (200507061800) JDK 1.5.0_04 The 'Override methods' menu item is enabled for the node with more top-level elements but is does nothing. Demonstration: 1) create new class Stuff3 with this code: interface Stuff1 { void doStuff1(); } interface Stuff2 extends Stuff1 { void doStuff2(); } class Stuff3 implements Stuff2 { } it's important to have if all in one file 2) select the Stuff3.java node in the project window 3) right click and call Tools | Override methods -> nothing happens It should be disabled or the warning should be poped up. For node containing only one top level element (common .java file) or for class node (one level below .java node) it works fine.
Override Methods should work for all top level classes, even if there are more such classes in one source. I am not able to reproduce this problem using your example. I have only noted that nothing happens when the action is invoked on interface (is it possible that this was your case?). There is nothing to override - I have added a warning message for this situation (to disable the action for interfaces would require some time expensive computation each time the current node is changed, thus I prefer this solution). It has been fixed in main trunk: /cvs/java/src/org/netbeans/modules/java/tools/Bundle.properties new revision: 1.17; previous revision: 1.16 /cvs/java/src/org/netbeans/modules/java/tools/OverrideAction.java new revision: 1.31; previous revision: 1.30
verified
Reorganization of java component