void (Project project, DataContext dataContext, GrTypeDefinition aClass, PsiElement aMember) { final Editor editor = dataContext != null ? CommonDataKeys.EDITOR.getData(dataContext) : null; if (aClass == null) { String message = RefactoringBundle.getCannotRefactorMessage(RefactoringBundle.message("is.not.supported.in.the.current.context", getRefactoringName())); CommonRefactoringUtil.showErrorHint(project, editor, message, getRefactoringName(), HelpID.MEMBERS_PULL_UP); return; } ArrayList<PsiClass> bases = RefactoringHierarchyUtil.createBasesList(aClass, false, true); if (bases.isEmpty()) { final GrTypeDefinition containingClass = (GrTypeDefinition)aClass.getContainingClass(); if (containingClass != null) { invokeImpl(project, dataContext, containingClass, aClass); return; } String message = RefactoringBundle.getCannotRefactorMessage( RefactoringBundle.message("class.does.not.have.base.classes.interfaces.in.current.project", aClass.getQualifiedName())); CommonRefactoringUtil.showErrorHint(project, editor, message, getRefactoringName(), HelpID.MEMBERS_PULL_UP); return; } mySubclass = aClass; GrMemberInfoStorage memberInfoStorage = new GrMemberInfoStorage((GrTypeDefinition)mySubclass, new MemberInfoBase.Filter<>() { @Override public boolean includeMember(GrMember element) { return true; } }); List<GrMemberInfo> members = memberInfoStorage.getClassMemberInfos(mySubclass); PsiManager manager = mySubclass.getManager(); for (GrMemberInfo member : members) { if (manager.areElementsEquivalent(member.getMember(), aMember)) { member.setChecked(true); break; } } final GrPullUpDialog dialog = new GrPullUpDialog(project, aClass, bases, memberInfoStorage, this); dialog.show(); }