summaryrefslogtreecommitdiff
path: root/include/Confirm.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/Confirm.h')
-rw-r--r--include/Confirm.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/include/Confirm.h b/include/Confirm.h
new file mode 100644
index 0000000..b56e0d2
--- /dev/null
+++ b/include/Confirm.h
@@ -0,0 +1,33 @@
+#ifndef __CONFIRM_H__
+#define __CONFIRM_H__
+#ifdef __cplusplus
+
+#include "Exceptions.h"
+#include "Action.h"
+#include "String.h"
+
+/*
+ * Cette classe sert à afficher une boîte de dialogue de confirmation.
+ * Constructeur:
+ * - titre = titre de la boite de dialogue
+ * - msg = message a afficher
+ * - url = url de cette boite
+ * - yes = action a effectuer si on clique sur Oui
+ * - no = action a effectuer si on clique sur Non.
+ */
+
+class Confirm : public Action {
+ public:
+ Confirm(const String & titre, const String & msg, const String & url, Action * yes, Action * no = 0);
+ virtual ~Confirm() { }
+ virtual String GetTitle();
+ virtual void Do(Variables *, Handle *);
+ private:
+ String tit, msg;
+ Action * NYes, * NNo;
+};
+
+#else
+#error This only works with a C++ compiler
+#endif
+#endif