Search in sources :

Example 1 with FileTemplatesScheme

use of com.intellij.ide.fileTemplates.FileTemplatesScheme in project intellij-community by JetBrains.

the class ChangeSchemaCombo method createPopupActionGroup.

@NotNull
@Override
protected DefaultActionGroup createPopupActionGroup(JComponent button) {
    DefaultActionGroup group = new DefaultActionGroup(new ChangeSchemaAction(FileTemplatesScheme.DEFAULT));
    FileTemplatesScheme scheme = myConfigurable.getManager().getProjectScheme();
    if (scheme != null) {
        group.add(new ChangeSchemaAction(scheme));
    }
    return group;
}
Also used : DefaultActionGroup(com.intellij.openapi.actionSystem.DefaultActionGroup) FileTemplatesScheme(com.intellij.ide.fileTemplates.FileTemplatesScheme) NotNull(org.jetbrains.annotations.NotNull)

Example 2 with FileTemplatesScheme

use of com.intellij.ide.fileTemplates.FileTemplatesScheme in project intellij-community by JetBrains.

the class FileTemplateManagerImpl method loadState.

@Override
public void loadState(State state) {
    XmlSerializerUtil.copyBean(state, myState);
    FileTemplatesScheme scheme = myProjectScheme != null && myProjectScheme.getName().equals(state.SCHEME) ? myProjectScheme : FileTemplatesScheme.DEFAULT;
    setScheme(scheme);
}
Also used : FileTemplatesScheme(com.intellij.ide.fileTemplates.FileTemplatesScheme)

Aggregations

FileTemplatesScheme (com.intellij.ide.fileTemplates.FileTemplatesScheme)2 DefaultActionGroup (com.intellij.openapi.actionSystem.DefaultActionGroup)1 NotNull (org.jetbrains.annotations.NotNull)1