mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-25 00:38:24 -05:00
d113aa91ca
When a WpaMsg item to the QValueList WpaMsgList, there's no constructor that the QValueList can call. This is a port of the fix from the stable branch where it builds fine.
35 lines
670 B
C++
35 lines
670 B
C++
#ifndef WPAMSG_H
|
|
#define WPAMSG_H
|
|
|
|
class WpaMsg;
|
|
|
|
#if QT_VERSION >= 0x040000
|
|
#include <QDateTime>
|
|
#include <QLinkedList>
|
|
typedef QLinkedList<WpaMsg> WpaMsgList;
|
|
#else
|
|
#include <qdatetime.h>
|
|
typedef QValueList<WpaMsg> WpaMsgList;
|
|
#endif
|
|
|
|
class WpaMsg {
|
|
public:
|
|
WpaMsg() {}
|
|
WpaMsg(const QString &_msg, int _priority = 2)
|
|
: msg(_msg), priority(_priority)
|
|
{
|
|
timestamp = QDateTime::currentDateTime();
|
|
}
|
|
|
|
QString getMsg() const { return msg; }
|
|
int getPriority() const { return priority; }
|
|
QDateTime getTimestamp() const { return timestamp; }
|
|
|
|
private:
|
|
QString msg;
|
|
int priority;
|
|
QDateTime timestamp;
|
|
};
|
|
|
|
#endif /* WPAMSG_H */
|