mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
introduce beforeOKAction()
This commit is contained in:
+6
-1
@@ -35,7 +35,8 @@ public abstract class AbstractCustomizeWizardStep extends JPanel {
|
||||
|
||||
protected abstract String getHTMLFooter();
|
||||
|
||||
private static Color getSelectionBackground() {
|
||||
@NotNull
|
||||
protected static Color getSelectionBackground() {
|
||||
return ColorUtil.mix(UIUtil.getListSelectionBackground(), UIUtil.getLabelBackground(), .75);
|
||||
}
|
||||
|
||||
@@ -75,4 +76,8 @@ public abstract class AbstractCustomizeWizardStep extends JPanel {
|
||||
|
||||
public void beforeShown(boolean forward) {
|
||||
}
|
||||
|
||||
public boolean beforeOkAction() {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -141,6 +141,9 @@ public class CustomizeIDEWizardDialog extends DialogWrapper implements ActionLis
|
||||
|
||||
@Override
|
||||
protected void doOKAction() {
|
||||
for (AbstractCustomizeWizardStep step : mySteps) {
|
||||
if (!step.beforeOkAction()) return;
|
||||
}
|
||||
try {
|
||||
PluginManager.saveDisabledPlugins(PluginGroups.getInstance().getDisabledPluginIds(), false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user