IDEA-266420 New Project wIzard: dialog changes its size unexpectedly on IntelliJ Platform Plugin type selecting

GitOrigin-RevId: d4949346a344200006c4433ad7ba86cf32965941
This commit is contained in:
Vassiliy.Kudryashov
2021-04-15 01:12:49 +03:00
committed by intellij-monorepo-bot
parent b1747cbd4b
commit cc5552026d
2 changed files with 7 additions and 13 deletions
@@ -9,7 +9,8 @@ module.wizard.gradle.presentable.name=IntelliJ Platform Plugin
module.wizard.gradle.learn.title=Learn how to <a>build plugins with Gradle</a>
module.wizard.gradle.plugin.xml.template.display.name=plugin.xml in Gradle-based projects
module.wizard.devkit.simple.plugin.label=This project type is recommended for simple plugins, such as a custom UI theme. For more complex plugins, a Gradle-based project is <a>recommended</a>.
module.wizard.devkit.simple.plugin.label=<html>This project type is recommended for simple plugins, such as a custom UI theme.<br> \
For more complex plugins, a Gradle-based project is <a href="https://plugins.jetbrains.com/docs/intellij/getting-started.html?from=DevkitPluginModuleWizard">recommended</a>.
convert.devkit.to.gradle.notification=Migrate DevKit plugin to Gradle
convert.devkit.to.gradle.notification.content=Gradle-based setup is recommended for this project.
@@ -19,9 +19,8 @@ import com.intellij.openapi.startup.StartupManager;
import com.intellij.openapi.vfs.LocalFileSystem;
import com.intellij.openapi.vfs.VfsUtilCore;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.ui.HyperlinkLabel;
import com.intellij.util.ui.JBUI;
import com.intellij.util.ui.components.BorderLayoutPanel;
import com.intellij.util.ui.SwingHelper;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.idea.devkit.DevKitBundle;
@@ -30,9 +29,10 @@ import org.jetbrains.idea.devkit.projectRoots.IdeaJdk;
import org.jetbrains.idea.devkit.run.PluginConfigurationType;
import org.jetbrains.jps.model.java.JavaResourceRootType;
import javax.swing.*;
import java.awt.*;
import static java.awt.GridBagConstraints.*;
public class PluginModuleBuilder extends JavaModuleBuilder {
@Override
@@ -106,15 +106,8 @@ public class PluginModuleBuilder extends JavaModuleBuilder {
final ModuleWizardStep step = StdModuleTypes.JAVA.modifyProjectTypeStep(settingsStep, this);
if (step == null) return null;
final BorderLayoutPanel panel = JBUI.Panels.simplePanel(0, 4);
final HyperlinkLabel linkLabel = new HyperlinkLabel();
linkLabel.setHtmlText(DevKitBundle.message("module.wizard.devkit.simple.plugin.label"));
linkLabel.setHyperlinkTarget("https://plugins.jetbrains.com/docs/intellij/getting-started.html?from=DevkitPluginModuleWizard");
panel.addToCenter(linkLabel);
final JComponent component = step.getComponent();
component.add(panel, new GridBagConstraints(0, 1, 1, 1, 1.0, 1.0,
GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, JBUI.insetsTop(8), 0, 0));
step.getComponent().add(SwingHelper.createHtmlLabel(DevKitBundle.message("module.wizard.devkit.simple.plugin.label"), null, null),
new GridBagConstraints(0, 1, 1, 1, 1.0, 1.0, CENTER, HORIZONTAL, JBUI.insetsTop(8), 0, 0));
return step;
}
}