summaryrefslogtreecommitdiffstats
path: root/Source/QtDialog/CMakeSetupDialog.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2011-01-27 20:34:07 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2011-01-27 20:34:07 (GMT)
commit182eb7c7eff70bc5af6ca77adf15b59e87400f2f (patch)
treed4a2bd71cb9993e6d354e8913444baf0d3a9255f /Source/QtDialog/CMakeSetupDialog.cxx
parent451c5f61c26fc1db154605dc5e4b1c07d584b24b (diff)
parentdd2f81491e6e17681dd18882a8ccfa01fa32a3f7 (diff)
downloadCMake-182eb7c7eff70bc5af6ca77adf15b59e87400f2f.zip
CMake-182eb7c7eff70bc5af6ca77adf15b59e87400f2f.tar.gz
CMake-182eb7c7eff70bc5af6ca77adf15b59e87400f2f.tar.bz2
Merge topic 'dev/strict-mode'
dd2f814 Merge branch 'dev/add_test-working-directory' into dev/strict-mode 949d32c Unwatch manual variables upon removal in cmake-gui 3939032 Unwatch manual variables upon removal in ccmake 8354413 Add method to unwatch a manual variable 8ed3c85 Give a better message for unused variables 729db48 Fix ArgumentExpansion test expected results 89c2544 Checking for a definition is a usage 5625dee Don't output to stderr in the GUI ad25a96 Merge branch 'ImprovedDotSupport2' into dev/strict-mode c128abe Merge branch 'AddCMAKE_CURRENT_LIST_DIR' into dev/strict-mode 9bcaff0 Merge branch 'cmake-guiRememberAdvancedCheckbox' into dev/strict-mode 544d0c3 Fix expected output for WarnUninitialized test 4e3bea4 Update expected messages to new format 8e8c9e4 Don't check at destruction for usage 668e005 Use cmake::IssueMessage for warnings 88cd4c1 Use 'CMake Warning' versus 'warning' for CDash 3c3b98d Initialize the class before setting warn flags cf8b15a Ignore files under the CMakeFiles directory fd50f06 Don't check for unused vars at configure time 447a04c Don't warn during configure when doing everything b97ee21 Check for unused variables at the end of generate c18c977 When checking for variables, specify a reason 3f1121f Use a long int since Line is a long as well 2507f93 Change the failure case string to 'Unexpected' fe390a2 Add 'ArgumentExpansion' test 8dbb209 Wrong boolean value for CLI warnings d4ee998 Hard-code the --no-warn-unused-cli flag a267b99 Fix line lengths 82ed104 Flag that the directories have been set 5aa535b Add argument to arg parsing to not set directories 367e5c3 Revert "Revert "When calling CMake, set the args and the cache"" ab5d4e4 Revert "When calling CMake, set the args and the cache" 9b90040 When calling CMake, set the args and the cache fe56002 Fix long lines for KWStyle 5d30cfc Set a watch on variables added through the gui 33c63b1 Add a method to put a watch for variables 535253f Initialize the warning variables earlier cbb286c Fix the path detection to work for top-level 62be1f7 Initialize the usage stack earlier c6e7fab Factor out the checks for unused variables 5e41ba8 When using the API, check for Add vs. Remove dee1976 Fix typo in VariableUnusedViaUnset test f231ce5 Remove old false positive avoidance code a117e02 Revert "Add test for unused warnings at the end of scope" 2c82f2b Exempt CMAKE(CURRENT|PARENT)_LIST_FILE from usage 6d7d449 Ignore CLI warnings for ABI determination 7740a73 Only return local keys that are defined bef3aee Use the API so that warnings can be tracked 05cb0f4 Check for unused variables in the dtor 91c4c99 Add test for unused warnings at the end of scope ca90f67 Fix detection of unused variables when setting f7438ca Add test for unused detection via setting it 995cfb0 Don't warn if the variable wasn't defined aefc91d Add test for usage checks via unset a8e97f8 Remove VarRemoved code since it's been superceded 59463ef Rework CheckVariableForUnused usage f117423 Fix line lengths to be no more than 78 e49a935 Improve unused warning logic e01e40c Mark ARGC, ARGV*, and ARGN as used a17aff7 Ignore CMAKE_MATCH_* variables for usage 02a114d Add method to allow variables to be marked as used a0b0d23 CMAKE_DO_TRY_COMPILE is no longer used ae3eff3 Fix the path used for ignoring system warnings 056b441 Fix missing case for usage of a variable 980e048 Factor out checks for unused variables 83acb0a Remove now unused variables 3801463 Use built-ins for readability and maintainability 8b52015 Push the initialize and unused states when copying 439877f Be consistent with single and double quotes 4cf1706 Add documentation for check-system-vars b74777f Fix the spelling of the flag for warn-unused-vars b948120 Change logic of flag to turn off cli unused checks f047a17 Add test for uninitialized variables 75bda38 Add tests for unused command line variables 300fc15 Fix detection of system files d784e6a Run the unused variables check on the final pass 9efc057 VariableWatch is not available when bootstrapping 2e78224 Add a missing comma to the warning message 7499700 Add a flag to warn about system files fff9f6d Rename flags again and use variablewatch for cli 786e269 Add warn-unused to the Qt interface 636e6c4 Default to marking things as used 4ff0340 Rename find-unused to warn-unused d7999e9 Rename strict-mode to warn-uninitialized e141bc9 Detect unused variables d3e8eb5 Add flags to detect unused variables f332e14 Complete strict-mode checks for uninitialized vars 52f9637 Add method to get the local scope variables f794d58 Make --strict-mode option, and integrate with cmake-gui 48b5b85 Add a warning when variables are used uninitialized. cd626ea For macros make sure the FilePath points to a valid pointer in the args.
Diffstat (limited to 'Source/QtDialog/CMakeSetupDialog.cxx')
-rw-r--r--Source/QtDialog/CMakeSetupDialog.cxx16
1 files changed, 15 insertions, 1 deletions
diff --git a/Source/QtDialog/CMakeSetupDialog.cxx b/Source/QtDialog/CMakeSetupDialog.cxx
index 408dbac..c8c4bfa 100644
--- a/Source/QtDialog/CMakeSetupDialog.cxx
+++ b/Source/QtDialog/CMakeSetupDialog.cxx
@@ -118,8 +118,15 @@ CMakeSetupDialog::CMakeSetupDialog()
this, SLOT(doInstallForCommandLine()));
#endif
QMenu* OptionsMenu = this->menuBar()->addMenu(tr("&Options"));
- this->SuppressDevWarningsAction = OptionsMenu->addAction(tr("&Suppress dev Warnings (-Wno-dev)"));
+ this->SuppressDevWarningsAction =
+ OptionsMenu->addAction(tr("&Suppress dev Warnings (-Wno-dev)"));
this->SuppressDevWarningsAction->setCheckable(true);
+ this->WarnUninitializedAction =
+ OptionsMenu->addAction(tr("&Warn Uninitialized (--warn-uninitialized)"));
+ this->WarnUninitializedAction->setCheckable(true);
+ this->WarnUnusedAction =
+ OptionsMenu->addAction(tr("&Warn Unused (--warn-unused-vars)"));
+ this->WarnUnusedAction->setCheckable(true);
QAction* debugAction = OptionsMenu->addAction(tr("&Debug Output"));
debugAction->setCheckable(true);
@@ -247,6 +254,13 @@ void CMakeSetupDialog::initialize()
QObject::connect(this->SuppressDevWarningsAction, SIGNAL(triggered(bool)),
this->CMakeThread->cmakeInstance(), SLOT(setSuppressDevWarnings(bool)));
+ QObject::connect(this->WarnUninitializedAction, SIGNAL(triggered(bool)),
+ this->CMakeThread->cmakeInstance(),
+ SLOT(setWarnUninitializedMode(bool)));
+ QObject::connect(this->WarnUnusedAction, SIGNAL(triggered(bool)),
+ this->CMakeThread->cmakeInstance(),
+ SLOT(setWarnUnusedMode(bool)));
+
if(!this->SourceDirectory->text().isEmpty() ||
!this->BinaryDirectory->lineEdit()->text().isEmpty())
{