Search in sources :

Example 1 with ErrorOptionsProvider

use of com.intellij.profile.codeInspection.ui.ErrorOptionsProvider in project intellij-community by JetBrains.

the class ErrorHighlightingPanel method reset.

public void reset() {
    DaemonCodeAnalyzerSettings settings = DaemonCodeAnalyzerSettings.getInstance();
    myAutoreparseDelayField.setText(Integer.toString(settings.AUTOREPARSE_DELAY));
    myMarkMinHeight.setText(Integer.toString(settings.ERROR_STRIPE_MARK_MIN_HEIGHT));
    myNextErrorGoesToErrorsFirst.setSelected(settings.NEXT_ERROR_ACTION_GOES_TO_ERRORS_FIRST);
    for (ErrorOptionsProvider optionsProvider : myExtensions) {
        optionsProvider.reset();
    }
}
Also used : DaemonCodeAnalyzerSettings(com.intellij.codeInsight.daemon.DaemonCodeAnalyzerSettings) ErrorOptionsProvider(com.intellij.profile.codeInspection.ui.ErrorOptionsProvider)

Example 2 with ErrorOptionsProvider

use of com.intellij.profile.codeInspection.ui.ErrorOptionsProvider in project intellij-community by JetBrains.

the class ErrorHighlightingPanel method apply.

public void apply() throws ConfigurationException {
    DaemonCodeAnalyzerSettings settings = DaemonCodeAnalyzerSettings.getInstance();
    settings.AUTOREPARSE_DELAY = getAutoReparseDelay();
    settings.ERROR_STRIPE_MARK_MIN_HEIGHT = getErrorStripeMarkMinHeight();
    settings.NEXT_ERROR_ACTION_GOES_TO_ERRORS_FIRST = myNextErrorGoesToErrorsFirst.isSelected();
    for (ErrorOptionsProvider optionsProvider : myExtensions) {
        optionsProvider.apply();
    }
    UISettings.getInstance().fireUISettingsChanged();
}
Also used : DaemonCodeAnalyzerSettings(com.intellij.codeInsight.daemon.DaemonCodeAnalyzerSettings) ErrorOptionsProvider(com.intellij.profile.codeInspection.ui.ErrorOptionsProvider)

Example 3 with ErrorOptionsProvider

use of com.intellij.profile.codeInspection.ui.ErrorOptionsProvider in project intellij-community by JetBrains.

the class ErrorHighlightingPanel method isModified.

public boolean isModified() {
    DaemonCodeAnalyzerSettings settings = DaemonCodeAnalyzerSettings.getInstance();
    boolean isModified = settings.AUTOREPARSE_DELAY != getAutoReparseDelay();
    isModified |= getErrorStripeMarkMinHeight() != settings.ERROR_STRIPE_MARK_MIN_HEIGHT;
    isModified |= myNextErrorGoesToErrorsFirst.isSelected() != settings.NEXT_ERROR_ACTION_GOES_TO_ERRORS_FIRST;
    for (ErrorOptionsProvider optionsProvider : myExtensions) {
        isModified |= optionsProvider.isModified();
    }
    if (isModified)
        return true;
    return false;
}
Also used : DaemonCodeAnalyzerSettings(com.intellij.codeInsight.daemon.DaemonCodeAnalyzerSettings) ErrorOptionsProvider(com.intellij.profile.codeInspection.ui.ErrorOptionsProvider)

Aggregations

DaemonCodeAnalyzerSettings (com.intellij.codeInsight.daemon.DaemonCodeAnalyzerSettings)3 ErrorOptionsProvider (com.intellij.profile.codeInspection.ui.ErrorOptionsProvider)3