[cmake-commits] hoffman committed CMakeSetupDialog.cxx 1.32 1.33

cmake-commits at cmake.org cmake-commits at cmake.org
Thu Feb 14 09:14:06 EST 2008


Update of /cvsroot/CMake/CMake/Source/QtDialog
In directory public:/mounts/ram/cvs-serv3573

Modified Files:
	CMakeSetupDialog.cxx 
Log Message:
ENH: add a check before delete cache


Index: CMakeSetupDialog.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/QtDialog/CMakeSetupDialog.cxx,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- CMakeSetupDialog.cxx	13 Feb 2008 18:58:35 -0000	1.32
+++ CMakeSetupDialog.cxx	14 Feb 2008 14:14:04 -0000	1.33
@@ -543,9 +543,18 @@
 }
 
 void CMakeSetupDialog::doDeleteCache()
-{
+{   
+  QString title = tr("Delete Cache");
+  QString message = "Are you sure you want to delete the cache?";
+  QMessageBox::StandardButton btn;
+  btn = QMessageBox::information(this, title, message, 
+                                 QMessageBox::Yes | QMessageBox::No);
+  if(btn == QMessageBox::No)
+    {
+    return;
+    }
   QMetaObject::invokeMethod(this->CMakeThread->cmakeInstance(),
-    "deleteCache", Qt::QueuedConnection);
+                            "deleteCache", Qt::QueuedConnection);
 }
 
 void CMakeSetupDialog::doAbout()



More information about the Cmake-commits mailing list