I'm writing a intellij plugin to let people choose a class, I find the code the move method in intellij open source code.
The move method picture is like this which will show all project class.
but when I using the following code the pic is this
There is no recommend class, after I type some text, still nothing.
TreeClassChooser chooser = TreeClassChooserFactory.getInstance(myProject).createWithInnerClassesScopeChooser(
"choose serviceClass", GlobalSearchScope.projectScope(myProject), new ClassFilter() {
public boolean isAccepted(PsiClass aClass) {
return aClass.getParent() instanceof PsiFile && !aClass.isInterface();
}
}, srcClass);
chooser.selectDirectory(pojoClass.getContainingFile().getContainingDirectory());
chooser.showDialog();
That seems to be a bug in the IDE, fixed in the upcoming 2017.2 release.