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 "ui/simple_dialog.h"
18 
19 #include <QPair>
20 #include <QString>
21 
22 typedef QPair<QString,QString> MessagePair;
23 
24 class QCheckBox;
25 class QMessageBox;
26 class QWidget;
27 
28 // This might be constructed before Qt is initialized and must be a plain, non-Qt object.
30 {
31 public:
32  explicit SimpleDialog(QWidget *parent, ESD_TYPE_E type, int btn_mask, const char *msg_format, va_list ap);
33  ~SimpleDialog();
34 
35  static void displayQueuedMessages(QWidget *parent = 0);
36  static QString dontShowThisAgain();
37  void setDetailedText(QString text) { detailed_text_ = text; }
38  void setCheckBox(QCheckBox *cb) { check_box_ = cb; }
39  int exec();
40  void show();
41 
42 private:
43  const MessagePair splitMessage(QString &message) const;
44  QString detailed_text_;
45  QCheckBox *check_box_;
46  QMessageBox *message_box_;
47 };
48 
49 #endif // SIMPLE_DIALOG_H
Definition: simple_dialog.h:30
ESD_TYPE_E
Definition: simple_dialog.h:31