Wireshark  4.3.0
The Wireshark network protocol analyzer
simple_dialog.h
Go to the documentation of this file.
1 
10 #ifndef SIMPLE_DIALOG_H
11 #define SIMPLE_DIALOG_H
12 
13 #include <config.h>
14 
15 #include <stdio.h>
16 
17 #include <glib.h>
18 
19 #include "ui/simple_dialog.h"
20 
21 #include <QPair>
22 #include <QString>
23 
24 typedef QPair<QString,QString> MessagePair;
25 
26 class QCheckBox;
27 class QMessageBox;
28 class QWidget;
29 
30 // This might be constructed before Qt is initialized and must be a plain, non-Qt object.
32 {
33 public:
34  explicit SimpleDialog(QWidget *parent, ESD_TYPE_E type, int btn_mask, const char *msg_format, va_list ap);
35  ~SimpleDialog();
36 
37  static void displayQueuedMessages(QWidget *parent = 0);
38  static QString dontShowThisAgain();
39  void setDetailedText(QString text) { detailed_text_ = text; }
40  void setCheckBox(QCheckBox *cb) { check_box_ = cb; }
41  int exec();
42  void show();
43 
44 private:
45  const MessagePair splitMessage(QString &message) const;
46  QString detailed_text_;
47  QCheckBox *check_box_;
48  QMessageBox *message_box_;
49 };
50 
51 #endif // SIMPLE_DIALOG_H
Definition: simple_dialog.h:32
ESD_TYPE_E
Definition: simple_dialog.h:27