src/misc.cpp

changeset 25
256bb5c6b77f
parent 21
99225eac33ba
child 30
6b82f6a3ad53
--- a/src/misc.cpp	Sun Sep 08 17:44:58 2013 +0300
+++ b/src/misc.cpp	Sun Sep 08 19:56:11 2013 +0300
@@ -17,6 +17,7 @@
  */
 
 #include "misc.h"
+#include <QMessageBox>
 
 EXTERN_CONFIG (List, devBuildNames)
 EXTERN_CONFIG (List, releaseNames)
@@ -60,4 +61,11 @@
 		return path.mid (lastpos + 1);
 	
 	return path;
+}
+
+// =============================================================================
+// -----------------------------------------------------------------------------
+bool confirm (str text) {
+	return QMessageBox::question (null, QObject::tr ("Confirm"), text,
+		QMessageBox::Yes | QMessageBox::No, QMessageBox::No) != QMessageBox::No;
 }
\ No newline at end of file

mercurial