17 #ifndef QGSMESSAGEBAR_H 18 #define QGSMESSAGEBAR_H 93 void pushMessage(
const QString &title,
const QString &text,
const QString &showMore,
Qgis::MessageLevel level =
Qgis::Info,
int duration = 5 );
125 void pushSuccess(
const QString &title,
const QString &message );
133 void pushInfo(
const QString &title,
const QString &message );
141 void pushWarning(
const QString &title,
const QString &message );
149 void pushCritical(
const QString &title,
const QString &message );
152 void mousePressEvent( QMouseEvent *e )
override;
158 QList<QgsMessageBarItem *> mItems;
159 QMenu *mCloseMenu =
nullptr;
160 QToolButton *mCloseBtn =
nullptr;
161 QGridLayout *mLayout =
nullptr;
162 QLabel *mItemCount =
nullptr;
163 QAction *mActionCloseAll =
nullptr;
164 QTimer *mCountdownTimer =
nullptr;
165 QProgressBar *mCountProgress =
nullptr;
166 QString mCountStyleSheet;
170 void updateItemCount();
173 void updateCountdown();
174 void resetCountdown();
A bar for displaying non-blocking messages to the user.
MessageLevel
Level for messages This will be used both for message log and message bar in application.
void pushMessage(const QString &text, Qgis::MessageLevel level=Qgis::Info, int duration=5)
convenience method for pushing a message to the bar
QgsMessageBarItem * currentItem()