Package com.intellij.ide.util

Examples of com.intellij.ide.util.PropertiesComponent


        }
    }

    @Override
    public void apply() throws ConfigurationException {
        PropertiesComponent properties = PropertiesComponent.getInstance(project);
        properties.setValue("enableYiiStorm", String.valueOf(enableYiiStorm.isSelected()));
        properties.setValue("themeName", themeNameField.getText());
        properties.setValue("langName", langField.getText());
        properties.setValue("yiicFile", yiicFileField.getText());
        // properties.setValue("yiiConfigPath", yiiConfigPath.getText());
        // properties.setValue("yiiLitePath", yiiLitePath.getText());
        // properties.setValue("useYiiCompleter", String.valueOf(useYiiCompleter.isSelected()));
        // properties.setValue("useYiiMigrations", String.valueOf(useMigrationsCheckbox.isSelected()));
View Full Code Here


        _project = project;
        toolw = this;
        yiic = new Yiic();

        PropertiesComponent properties = PropertiesComponent.getInstance(getProject());
        yiiFile = properties.getValue("yiicFile");
        useMigrations = properties.getBoolean("useYiiMigrations", false);
        setMigrateLogText("");

        contentPane = new JPanel();
        contentPane.setLayout(new BorderLayout());
View Full Code Here

public class ProjectSettings {
  private static final String       LOMBOK_PLUGIN_ENABLED_IN_PROJECT_PROPERTY = "LombokPluginEnabledInProject";
  private static final Key<Boolean> LOMBOK_ENABLED_KEY                        = Key.create(LOMBOK_PLUGIN_ENABLED_IN_PROJECT_PROPERTY);

  public static boolean isEnabledInProject(@NotNull final Project project) {
    PropertiesComponent properties = PropertiesComponent.getInstance(project);
    return properties.getBoolean(LOMBOK_PLUGIN_ENABLED_IN_PROJECT_PROPERTY, DefaultSettings.PLUGIN_ENABLED_IN_PROJECT);
  }
View Full Code Here

    PropertiesComponent properties = PropertiesComponent.getInstance(project);
    return properties.getBoolean(LOMBOK_PLUGIN_ENABLED_IN_PROJECT_PROPERTY, DefaultSettings.PLUGIN_ENABLED_IN_PROJECT);
  }

  public static void setEnabledInProject(@NotNull final Project project, boolean value) {
    PropertiesComponent properties = PropertiesComponent.getInstance(project);
    properties.setValue(LOMBOK_PLUGIN_ENABLED_IN_PROJECT_PROPERTY, String.valueOf(value));

    project.putUserData(LOMBOK_ENABLED_KEY, value);
    //DaemonCodeAnalyser.getInstance(project).restart();
  }
View Full Code Here

            PsiClass psiClass = getDefaultClass(project);
            if (psiClass != null) {
                recentsManager.registerRecentEntry(getStoreKey(RECENT_EXTENDCLASS_KEY), psiClass.getQualifiedName());
            }
        }
        PropertiesComponent propertiesComponent = PropertiesComponent.getInstance(project);
        // restore last used options
        createAssociatedMarkupFileCheckBox.setSelected(propertiesComponent.getBoolean(getStoreKey(CREATE_MARKUP_KEY), false));
        chooseDifferentDestinationFolderCheckBox.setSelected(propertiesComponent.getBoolean(getStoreKey(CHOOSE_DIFFERENT_DESTINATION_KEY), true));

        // if we have only 1 destination, we dont offer a different folder selection
        if (WicketFileUtil.getResourceRoots(module).length < 2) {
            chooseDifferentDestinationFolderPanel.setVisible(false);
        } else {
View Full Code Here

        if (validateInput(inputString, extendsClass) && actionRunnable.run(inputString, extendsClass, createMarkup, markupDirectory)) {

            // remember last extended class and options
            RecentsManager.getInstance(project).registerRecentEntry(getStoreKey(RECENT_EXTENDCLASS_KEY), extendsClass);
            PropertiesComponent propertiesComponent = PropertiesComponent.getInstance(project);
            propertiesComponent.setValue(getStoreKey(CREATE_MARKUP_KEY), Boolean.toString(createMarkup));
            propertiesComponent.setValue(getStoreKey(CHOOSE_DIFFERENT_DESTINATION_KEY), Boolean.toString(chooseDifferentDestination));

            super.doOKAction();
        }
    }
View Full Code Here

    private void loadValues() {
        LOG.info("Loading SortPom configuration");
        SortPomConfigurationData store = createDefaultConfiguration();

        PropertiesComponent propertiesComponent = PropertiesComponent.getInstance(project);
        boolean success = propertiesComponent.loadFields(store);

        if (success) {
            updateFields(store);
        } else {
            LOG.error("Could not load SortPom configuration");
View Full Code Here

                sortPropertiesField.isSelected(),
                expandEmptyElementsField.isSelected(),
                keepBlankLinesField.isSelected(),
                indentBlankLines.isSelected());

        PropertiesComponent propertiesComponent = PropertiesComponent.getInstance(project);
        boolean success = propertiesComponent.saveFields(store);

        if (!success) {
            LOG.error("Could not save SortPom configuration");
        }
    }
View Full Code Here

        setContentPane(contentPane);
        setModal(true);
        setBounds(500, 500, 400, 200);
        getRootPane().setDefaultButton(buttonOK);

        PropertiesComponent properties = PropertiesComponent.getInstance(currentAction.getProject());
        String themeName = properties.getValue("themeName");
        if (themeName != null) {
            themeNameField.setText(themeName);
        }

        String yiicFile = properties.getValue("yiicFile");
        if (yiicFile != null) {
            yiicFileField.setText(yiicFile);
        }

        yiicPathSelect.addActionListener(new ActionListener() {
View Full Code Here

    }

    private void onOK() {
// add your code here

        PropertiesComponent properties = PropertiesComponent.getInstance(currentAction.getProject());
        String themeName = themeNameField.getText();
        if (themeName != null) {
            properties.setValue("themeName", themeName);
        }

        String selectedFile = yiicFileField.getText();
        if (selectedFile != null) {
            properties.setValue("yiicFile", selectedFile);
        }
        ConfigForm.showed = false;
        dispose();
    }
View Full Code Here

TOP

Related Classes of com.intellij.ide.util.PropertiesComponent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.