mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-10-06 06:21:16 +07:00
IDEA-25139: Proper caret placement for methods, if "next line" brace style is in use.
This commit is contained in:
+4
@@ -71,6 +71,10 @@ public class PlainEnterProcessor implements EnterProcessor {
|
||||
else if (element instanceof PsiDoWhileStatement) {
|
||||
body = ((PsiDoWhileStatement)element).getBody();
|
||||
}
|
||||
else if (element instanceof PsiMethod) {
|
||||
PsiCodeBlock methodBody = ((PsiMethod)element).getBody();
|
||||
if (methodBody != null) return methodBody;
|
||||
}
|
||||
|
||||
return body instanceof PsiBlockStatement ? ((PsiBlockStatement)body).getCodeBlock() : null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user