Add WarningLabel and WarningMessageWidget to App, and add some reference event to EventCenter
This commit is contained in:
24
src/components/WarningLabel.h
Normal file
24
src/components/WarningLabel.h
Normal file
@@ -0,0 +1,24 @@
|
||||
#ifndef _GUI_WARNINGLABEL_H__
|
||||
#define _GUI_WARNINGLABEL_H__
|
||||
#include <QWidget>
|
||||
#include <QString>
|
||||
|
||||
|
||||
enum WarningType{
|
||||
ERROR, WARNING
|
||||
};
|
||||
|
||||
class WarningLabel: public QWidget {
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit WarningLabel(QWidget *aParent, WarningType aType,const QString& aMessageTime, const QString& content);
|
||||
~WarningLabel() =default;
|
||||
protected:
|
||||
void paintEvent(QPaintEvent * aEvent);
|
||||
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
#endif // __WARNINGLABEL_H__
|
||||
Reference in New Issue
Block a user