Make QSystemTrayIcon::showMessage invokable
Qt WebKit's HTML5 web notifications rely on QSystemTrayIcon::showMessage to be invokable since the lower WebCore components can not link directly to QWidgets. Change-Id: I952de47ed8a90553a8f1ac30256d77ef6014da44 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
This commit is contained in:
parent
5e4b9f1154
commit
9e7fa9f72b
@ -380,6 +380,8 @@ bool QSystemTrayIcon::supportsMessages()
|
||||
On Mac OS X, the Growl notification system must be installed for this function to
|
||||
display messages.
|
||||
|
||||
Has been turned into a slot in Qt 5.2.
|
||||
|
||||
\sa show(), supportsMessages()
|
||||
*/
|
||||
void QSystemTrayIcon::showMessage(const QString& title, const QString& msg,
|
||||
|
@ -94,8 +94,6 @@ public:
|
||||
static bool supportsMessages();
|
||||
|
||||
enum MessageIcon { NoIcon, Information, Warning, Critical };
|
||||
void showMessage(const QString &title, const QString &msg,
|
||||
MessageIcon icon = Information, int msecs = 10000);
|
||||
|
||||
QRect geometry() const;
|
||||
bool isVisible() const;
|
||||
@ -104,6 +102,8 @@ public Q_SLOTS:
|
||||
void setVisible(bool visible);
|
||||
inline void show() { setVisible(true); }
|
||||
inline void hide() { setVisible(false); }
|
||||
void showMessage(const QString &title, const QString &msg,
|
||||
QSystemTrayIcon::MessageIcon icon = QSystemTrayIcon::Information, int msecs = 10000);
|
||||
|
||||
Q_SIGNALS:
|
||||
void activated(QSystemTrayIcon::ActivationReason reason);
|
||||
|
Loading…
Reference in New Issue
Block a user