GUI: Add option to show debug warnings in checking log.

This commit is contained in:
Kimmo Varis 2010-08-29 09:38:03 +03:00
parent 20a4f1e195
commit b0fa7bfd8c
4 changed files with 29 additions and 4 deletions

View File

@ -48,6 +48,7 @@ ShowTypes;
#define SETTINGS_CHECK_THREADS "Check threads"
#define SETTINGS_SHOW_FULL_PATH "Show full path"
#define SETTINGS_SHOW_NO_ERRORS "Show no errors message"
#define SETTINGS_SHOW_DEBUG_WARNINGS "Show debug warnings"
#define SETTINGS_SAVE_ALL_ERRORS "Save all errors"
#define SETTINGS_SAVE_FULL_PATH "Save full path"
#define SETTINGS_CHECK_DIALOG_WIDTH "Check dialog width"

View File

@ -361,7 +361,7 @@ Settings MainWindow::GetCppcheckSettings()
}
result.debug = false;
result.debugwarnings = false;
result.debugwarnings = mSettings->value(SETTINGS_SHOW_DEBUG_WARNINGS, 0).toBool();
result._checkCodingStyle = true;
result._errorsOnly = false;
result._verbose = true;

View File

@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>589</width>
<height>274</height>
<height>281</height>
</rect>
</property>
<property name="windowTitle">
@ -17,7 +17,7 @@
<item>
<widget class="QTabWidget" name="tabWidget">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
@ -61,6 +61,13 @@
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="mShowDebugWarnings">
<property name="text">
<string>Show internal warnings in log</string>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer_2">
<property name="orientation">
@ -164,6 +171,22 @@
</item>
</layout>
</widget>
<tabstops>
<tabstop>tabWidget</tabstop>
<tabstop>mJobs</tabstop>
<tabstop>mForce</tabstop>
<tabstop>mShowFullPath</tabstop>
<tabstop>mShowNoErrorsMessage</tabstop>
<tabstop>mShowDebugWarnings</tabstop>
<tabstop>mListWidget</tabstop>
<tabstop>mButtonAdd</tabstop>
<tabstop>mButtonDelete</tabstop>
<tabstop>mButtonModify</tabstop>
<tabstop>mButtonDefault</tabstop>
<tabstop>mSaveAllErrors</tabstop>
<tabstop>mSaveFullPath</tabstop>
<tabstop>mButtons</tabstop>
</tabstops>
<resources/>
<connections>
<connection>

View File

@ -46,7 +46,7 @@ SettingsDialog::SettingsDialog(QSettings *programSettings,
mUI.mForce->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_CHECK_FORCE, false).toBool()));
mUI.mShowFullPath->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_SHOW_FULL_PATH, false).toBool()));
mUI.mShowNoErrorsMessage->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_SHOW_NO_ERRORS, false).toBool()));
mUI.mShowDebugWarnings->setCheckState(BoolToCheckState(programSettings->value(SETTINGS_SHOW_DEBUG_WARNINGS, false).toBool()));
connect(mUI.mButtonAdd, SIGNAL(clicked()),
this, SLOT(AddApplication()));
@ -122,6 +122,7 @@ void SettingsDialog::SaveCheckboxValues()
SaveCheckboxValue(mUI.mSaveFullPath, SETTINGS_SAVE_FULL_PATH);
SaveCheckboxValue(mUI.mShowFullPath, SETTINGS_SHOW_FULL_PATH);
SaveCheckboxValue(mUI.mShowNoErrorsMessage, SETTINGS_SHOW_NO_ERRORS);
SaveCheckboxValue(mUI.mShowDebugWarnings, SETTINGS_SHOW_DEBUG_WARNINGS);
}
void SettingsDialog::SaveCheckboxValue(QCheckBox *box, const QString &name)