Search in sources :

Example 1 with PaletteItemProvider

use of com.intellij.ide.palette.PaletteItemProvider in project intellij-community by JetBrains.

the class PaletteWindow method collectCurrentGroups.

private ArrayList<PaletteGroup> collectCurrentGroups(@Nullable VirtualFile selectedFile) {
    ArrayList<PaletteGroup> result = new ArrayList<>();
    if (selectedFile != null) {
        for (PaletteItemProvider provider : myProviders) {
            PaletteGroup[] groups = provider.getActiveGroups(selectedFile);
            Collections.addAll(result, groups);
        }
    }
    return result;
}
Also used : PaletteItemProvider(com.intellij.ide.palette.PaletteItemProvider) PaletteGroup(com.intellij.ide.palette.PaletteGroup)

Aggregations

PaletteGroup (com.intellij.ide.palette.PaletteGroup)1 PaletteItemProvider (com.intellij.ide.palette.PaletteItemProvider)1