DefaultActionGroup (@NotNull List<? extends MergeableLineMarkerInfo<?>> markers) { DefaultActionGroup commonActionGroup = null; boolean first = true; for (MergeableLineMarkerInfo<?> marker : markers) { GutterIconRenderer renderer = marker.createGutterRenderer(); if (renderer != null) { ActionGroup actions = renderer.getPopupMenuActions(); if (actions != null) { if (commonActionGroup == null) { commonActionGroup = new DefaultActionGroup(); } if (!first) { commonActionGroup.add(Separator.getInstance()); } first = false; commonActionGroup.addAll(actions); } } } return commonActionGroup; }