DefaultActionGroup (RadComponent component, final PsiField boundField) { final DefaultActionGroup actionGroup = new DefaultActionGroup(); final EventSetDescriptor[] eventSetDescriptors; try { BeanInfo beanInfo = Introspector.getBeanInfo(component.getComponentClass()); eventSetDescriptors = beanInfo.getEventSetDescriptors(); } catch (IntrospectionException e) { LOG.error(e); return null; } PsiFile boundClassFile = boundField.getContainingFile(); if (boundClassFile == null) { return null; } final LocalSearchScope scope = new LocalSearchScope(boundClassFile); ReferencesSearch.search(boundField, scope).forEach(ref -> { final PsiElement element = ref.getElement(); if (element.getParent() instanceof PsiReferenceExpression refExpr) { if (refExpr.getParent() instanceof PsiMethodCallExpression methodCall) { final PsiElement psiElement = refExpr.resolve(); if (psiElement instanceof PsiMethod method) { for(EventSetDescriptor eventSetDescriptor: eventSetDescriptors) { if (Objects.equals(eventSetDescriptor.getAddListenerMethod().getName(), method.getName())) { final String eventName = eventSetDescriptor.getName(); final PsiExpression[] args = methodCall.getArgumentList().getExpressions(); if (args.length > 0) { addListenerRef(actionGroup, eventName, args[0]); } } } } } } return true; }); return actionGroup; }