I've been searching for hours in the SDK's source but cannot find any "easy" way to expand the Project View's tree to a given PsiElement without also selecting it.
The only thing working is this:
but it also selects the associated node in the tree, whereas I'd like the previous selection to remain.
which don't work consistently depending on the tree's state, and even:
JTree.scrollPathToVisible(new TreePath(treeUI.getNodeForElement(psiElement, false)))
but AbstractTreeUI.getNodeForElement returns null most of the time.
Any help would be greatly appreciated,
Thank you very much in advance.