diff --git a/gui/common.h b/gui/common.h index bbe2f4821..903eefe1d 100644 --- a/gui/common.h +++ b/gui/common.h @@ -82,6 +82,7 @@ ShowTypes; #define SETTINGS_LANGUAGE "Application language" #define SETTINGS_GLOBAL_INCLUDE_PATHS "Global include paths" #define SETTINGS_INLINE_SUPPRESSIONS "Inline suppressions" +#define SETTINGS_INCONCLUSIVE_ERRORS "Inconclusive errors" /// @} #endif diff --git a/gui/erroritem.cpp b/gui/erroritem.cpp index b72e2422f..6972d8cfe 100644 --- a/gui/erroritem.cpp +++ b/gui/erroritem.cpp @@ -20,6 +20,7 @@ ErrorItem::ErrorItem() : severity(Severity::none) + , inconclusive(false) { } diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index efa99910b..76b4cc281 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -396,6 +396,7 @@ Settings MainWindow::GetCppcheckSettings() result._xml = false; result._jobs = mSettings->value(SETTINGS_CHECK_THREADS, 1).toInt(); result._inlineSuppressions = mSettings->value(SETTINGS_INLINE_SUPPRESSIONS, false).toBool(); + result.inconclusive = mSettings->value(SETTINGS_INCONCLUSIVE_ERRORS, false).toBool(); if (result._jobs <= 0) { diff --git a/gui/settings.ui b/gui/settings.ui index f4366013f..2a51d443d 100644 --- a/gui/settings.ui +++ b/gui/settings.ui @@ -17,7 +17,7 @@ - 2 + 0 @@ -328,6 +328,33 @@ + + + Advanced + + + + + + &Show inconclusive errors + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + @@ -349,12 +376,20 @@ mShowFullPath mShowNoErrorsMessage mShowDebugWarnings + mInlineSuppressions + mListIncludePaths + mBtnAddIncludePath + mBtnEditIncludePath + mBtnRemoveIncludePath mListWidget mBtnAddApplication mBtnEditApplication + mBtnRemoveApplication mBtnDefaultApplication mSaveAllErrors mSaveFullPath + mListLanguages + mEnableInconclusive mButtons diff --git a/gui/settingsdialog.cpp b/gui/settingsdialog.cpp index c4ff52427..8eed6ce04 100644 --- a/gui/settingsdialog.cpp +++ b/gui/settingsdialog.cpp @@ -54,6 +54,7 @@ SettingsDialog::SettingsDialog(QSettings *programSettings, mUI.mSaveAllErrors->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_SAVE_ALL_ERRORS, false).toBool())); mUI.mSaveFullPath->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_SAVE_FULL_PATH, false).toBool())); mUI.mInlineSuppressions->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_INLINE_SUPPRESSIONS, false).toBool())); + mUI.mEnableInconclusive->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_INCONCLUSIVE_ERRORS, false).toBool())); connect(mUI.mButtons, SIGNAL(accepted()), this, SLOT(Ok())); connect(mUI.mButtons, SIGNAL(rejected()), this, SLOT(reject())); @@ -175,6 +176,7 @@ void SettingsDialog::SaveSettingValues() SaveCheckboxValue(mUI.mShowNoErrorsMessage, SETTINGS_SHOW_NO_ERRORS); SaveCheckboxValue(mUI.mShowDebugWarnings, SETTINGS_SHOW_DEBUG_WARNINGS); SaveCheckboxValue(mUI.mInlineSuppressions, SETTINGS_INLINE_SUPPRESSIONS); + SaveCheckboxValue(mUI.mEnableInconclusive, SETTINGS_INCONCLUSIVE_ERRORS); QListWidgetItem *currentLang = mUI.mListLanguages->currentItem(); const QString langcode = currentLang->data(LangCodeRole).toString();