@Override
 protected void addReferenceAtCaret(Collection<PsiReference> refs) {
   final V variable = getLocalVariable();
   if (variable != null) {
     for (PsiReference reference : ReferencesSearch.search(variable)) {
       refs.add(reference);
     }
   } else {
     refs.clear();
   }
 }
 @Nullable
 private IProperty getSelectedProperty() {
   final Collection<DefaultMutableTreeNode> selectedNode = getSelectedNodes();
   if (selectedNode.isEmpty()) {
     return null;
   }
   final ResourceBundleEditorViewElement element =
       getSelectedElement(ContainerUtil.getFirstItem(selectedNode));
   return element instanceof ResourceBundlePropertyStructureViewElement
       ? ((ResourceBundlePropertyStructureViewElement) element).getProperty()
       : null;
 }
 @Nullable
 public ResourceBundleEditorViewElement getSelectedElementIfOnlyOne() {
   final Collection<ResourceBundleEditorViewElement> selectedElements = getSelectedElements();
   return selectedElements.size() == 1 ? ContainerUtil.getFirstItem(selectedElements) : null;
 }