mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-157379 'Project Files Tree', copy references doesn't output same content with single or multiple files
use the old way if PSI_ELEMENT_ARRAY returns nothing, fix tests
This commit is contained in:
@@ -154,6 +154,10 @@ public class CopyReferenceAction extends DumbAwareAction {
|
||||
}
|
||||
}
|
||||
|
||||
if (elements.isEmpty()) {
|
||||
ContainerUtil.addIfNotNull(elements, CommonDataKeys.PSI_ELEMENT.getData(dataContext));
|
||||
}
|
||||
|
||||
if (elements.isEmpty() && editor == null) {
|
||||
final Project project = CommonDataKeys.PROJECT.getData(dataContext);
|
||||
VirtualFile[] files = CommonDataKeys.VIRTUAL_FILE_ARRAY.getData(dataContext);
|
||||
|
||||
Reference in New Issue
Block a user