if (project == null) return AnAction.EMPTY_ARRAY;
DomCollectionChildDescription[] descriptions = getDomCollectionChildDescriptions(e);
final List<AnAction> actions = new ArrayList<AnAction>();
for (DomCollectionChildDescription description : descriptions) {
final TypeChooser chooser = DomManager.getDomManager(project).getTypeChooserManager().getTypeChooser(description.getType());
for (Type type : chooser.getChooserTypes()) {
final Class<?> rawType = ReflectionUtil.getRawType(type);
String name = ElementPresentationManager.getTypeName(rawType);
Icon icon = null;
if (!showAsPopup() || descriptions.length == 1) {