mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-30 10:20:15 +07:00
disable Override method intention for constructor
This commit is contained in:
@@ -41,7 +41,7 @@ public class ImplementAbstractMethodAction extends BaseIntentionAction {
|
||||
int offset = editor.getCaretModel().getOffset();
|
||||
final PsiMethod method = findMethod(file, offset);
|
||||
|
||||
if (method == null || !method.isValid()) return false;
|
||||
if (method == null || !method.isValid() || method.isConstructor()) return false;
|
||||
setText(getIntentionName(method));
|
||||
|
||||
if (!method.getManager().isInProject(method)) return false;
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
// "Override method 'A'" "false"
|
||||
class A {
|
||||
<caret>A() {}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
Reference in New Issue
Block a user