Search in sources :

Example 1 with GroovyLibraryDescription

use of org.jetbrains.plugins.groovy.config.GroovyLibraryDescription in project intellij-community by JetBrains.

the class GroovySdkWizardStepBase method getPanel.

protected LibraryOptionsPanel getPanel() {
    if (myPanel == null) {
        final GroovyLibraryDescription libraryDescription = myFramework == null ? new GroovyLibraryDescription() : myFramework.createLibraryDescription();
        final String baseDirPath = myBasePath != null ? FileUtil.toSystemIndependentName(myBasePath) : "";
        myPanel = new LibraryOptionsPanel(libraryDescription, baseDirPath, FrameworkLibraryVersionFilter.ALL, myLibrariesContainer, false);
        Disposer.register(myDisposable, myPanel);
    }
    return myPanel;
}
Also used : LibraryOptionsPanel(com.intellij.facet.impl.ui.libraries.LibraryOptionsPanel) GroovyLibraryDescription(org.jetbrains.plugins.groovy.config.GroovyLibraryDescription)

Example 2 with GroovyLibraryDescription

use of org.jetbrains.plugins.groovy.config.GroovyLibraryDescription in project intellij-community by JetBrains.

the class MvcFramework method configureAsLibraryDependency.

protected void configureAsLibraryDependency(@NotNull Module module) {
    final GroovyLibraryDescription description = createLibraryDescription();
    final AddCustomLibraryDialog dialog = AddCustomLibraryDialog.createDialog(description, module, null);
    dialog.setTitle("Change " + getDisplayName() + " SDK version");
    if (dialog.showAndGet())
        module.putUserData(UPGRADE, Boolean.TRUE);
}
Also used : AddCustomLibraryDialog(com.intellij.openapi.roots.ui.configuration.libraries.AddCustomLibraryDialog) GroovyLibraryDescription(org.jetbrains.plugins.groovy.config.GroovyLibraryDescription)

Example 3 with GroovyLibraryDescription

use of org.jetbrains.plugins.groovy.config.GroovyLibraryDescription in project intellij-community by JetBrains.

the class MvcUpgradeAction method actionPerformed.

@Override
protected void actionPerformed(@NotNull AnActionEvent e, @NotNull final Module module, @NotNull final MvcFramework framework) {
    final GroovyLibraryDescription description = framework.createLibraryDescription();
    final AddCustomLibraryDialog dialog = AddCustomLibraryDialog.createDialog(description, module, modifiableRootModel -> removeOldMvcSdk(framework, modifiableRootModel));
    dialog.setTitle("Change " + framework.getDisplayName() + " SDK version");
    if (dialog.showAndGet()) {
        module.putUserData(MvcFramework.UPGRADE, Boolean.TRUE);
        module.putUserData(MvcModuleStructureUtil.LAST_MVC_VERSION, null);
    }
}
Also used : AddCustomLibraryDialog(com.intellij.openapi.roots.ui.configuration.libraries.AddCustomLibraryDialog) GroovyLibraryDescription(org.jetbrains.plugins.groovy.config.GroovyLibraryDescription)

Aggregations

GroovyLibraryDescription (org.jetbrains.plugins.groovy.config.GroovyLibraryDescription)3 AddCustomLibraryDialog (com.intellij.openapi.roots.ui.configuration.libraries.AddCustomLibraryDialog)2 LibraryOptionsPanel (com.intellij.facet.impl.ui.libraries.LibraryOptionsPanel)1