diff --git a/src/gui/kernel/qplatformsystemtrayicon.cpp b/src/gui/kernel/qplatformsystemtrayicon.cpp index 7bc61e6e6e..ae87805856 100644 --- a/src/gui/kernel/qplatformsystemtrayicon.cpp +++ b/src/gui/kernel/qplatformsystemtrayicon.cpp @@ -118,7 +118,7 @@ QPlatformSystemTrayIcon::~QPlatformSystemTrayIcon() */ /*! - \fn void QPlatformSystemTrayIcon::showMessage(const QString &msg, const QString &title, + \fn void QPlatformSystemTrayIcon::showMessage(const QString &title, const QString &msg, const QIcon &icon, MessageIcon iconType, int secs) Shows a balloon message for the entry with the given \a title, message \a msg and \a icon for the time specified in \a secs. \a iconType is used as a hint for the implementing platform. diff --git a/src/gui/kernel/qplatformsystemtrayicon.h b/src/gui/kernel/qplatformsystemtrayicon.h index 499b5fca17..9bbaf5e9ca 100644 --- a/src/gui/kernel/qplatformsystemtrayicon.h +++ b/src/gui/kernel/qplatformsystemtrayicon.h @@ -69,7 +69,7 @@ public: virtual void updateToolTip(const QString &tooltip) = 0; virtual void updateMenu(QPlatformMenu *menu) = 0; virtual QRect geometry() const = 0; - virtual void showMessage(const QString &msg, const QString &title, + virtual void showMessage(const QString &title, const QString &msg, const QIcon &icon, MessageIcon iconType, int secs) = 0; virtual bool isSystemTrayAvailable() const = 0; diff --git a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h index c527c478ff..c426cacc35 100755 --- a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h +++ b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h @@ -57,7 +57,7 @@ public: virtual void updateToolTip(const QString &toolTip); virtual void updateMenu(QPlatformMenu *menu); virtual QRect geometry() const; - virtual void showMessage(const QString &msg, const QString &title, + virtual void showMessage(const QString &title, const QString &msg, const QIcon& icon, MessageIcon iconType, int secs); virtual bool isSystemTrayAvailable() const; diff --git a/src/widgets/util/qsystemtrayicon.cpp b/src/widgets/util/qsystemtrayicon.cpp index 7d04cab05e..30ef7e82e5 100644 --- a/src/widgets/util/qsystemtrayicon.cpp +++ b/src/widgets/util/qsystemtrayicon.cpp @@ -718,8 +718,8 @@ void QSystemTrayIconPrivate::updateToolTip_sys_qpa() qpa_sys->updateToolTip(toolTip); } -void QSystemTrayIconPrivate::showMessage_sys_qpa(const QString &message, - const QString &title, +void QSystemTrayIconPrivate::showMessage_sys_qpa(const QString &title, + const QString &message, QSystemTrayIcon::MessageIcon icon, int msecs) { @@ -737,7 +737,7 @@ void QSystemTrayIconPrivate::showMessage_sys_qpa(const QString &message, default: break; } - qpa_sys->showMessage(message, title, notificationIcon, + qpa_sys->showMessage(title, message, notificationIcon, static_cast(icon), msecs); } diff --git a/src/widgets/util/qsystemtrayicon_p.h b/src/widgets/util/qsystemtrayicon_p.h index ce88313707..fdf91d4c43 100644 --- a/src/widgets/util/qsystemtrayicon_p.h +++ b/src/widgets/util/qsystemtrayicon_p.h @@ -77,7 +77,7 @@ public: void updateToolTip_sys(); void updateMenu_sys(); QRect geometry_sys() const; - void showMessage_sys(const QString &msg, const QString &title, QSystemTrayIcon::MessageIcon icon, int secs); + void showMessage_sys(const QString &title, const QString &msg, QSystemTrayIcon::MessageIcon icon, int secs); static bool isSystemTrayAvailable_sys(); static bool supportsMessages_sys(); @@ -98,7 +98,7 @@ private: void updateToolTip_sys_qpa(); void updateMenu_sys_qpa(); QRect geometry_sys_qpa() const; - void showMessage_sys_qpa(const QString &msg, const QString &title, QSystemTrayIcon::MessageIcon icon, int secs); + void showMessage_sys_qpa(const QString &title, const QString &msg, QSystemTrayIcon::MessageIcon icon, int secs); }; class QBalloonTip : public QWidget diff --git a/src/widgets/util/qsystemtrayicon_qpa.cpp b/src/widgets/util/qsystemtrayicon_qpa.cpp index 08764b405d..7dc848d3ab 100644 --- a/src/widgets/util/qsystemtrayicon_qpa.cpp +++ b/src/widgets/util/qsystemtrayicon_qpa.cpp @@ -111,13 +111,11 @@ bool QSystemTrayIconPrivate::supportsMessages_sys() return false; } -void QSystemTrayIconPrivate::showMessage_sys(const QString &message, - const QString &title, - QSystemTrayIcon::MessageIcon icon, - int msecs) +void QSystemTrayIconPrivate::showMessage_sys(const QString &title, const QString &message, + QSystemTrayIcon::MessageIcon icon, int msecs) { if (qpa_sys) - showMessage_sys_qpa(message, title, icon, msecs); + showMessage_sys_qpa(title, message, icon, msecs); } QT_END_NAMESPACE diff --git a/src/widgets/util/qsystemtrayicon_x11.cpp b/src/widgets/util/qsystemtrayicon_x11.cpp index 8fbbc96f6c..eee100d279 100644 --- a/src/widgets/util/qsystemtrayicon_x11.cpp +++ b/src/widgets/util/qsystemtrayicon_x11.cpp @@ -341,11 +341,11 @@ bool QSystemTrayIconPrivate::supportsMessages_sys() return true; } -void QSystemTrayIconPrivate::showMessage_sys(const QString &message, const QString &title, +void QSystemTrayIconPrivate::showMessage_sys(const QString &title, const QString &message, QSystemTrayIcon::MessageIcon icon, int msecs) { if (qpa_sys) { - showMessage_sys_qpa(message, title, icon, msecs); + showMessage_sys_qpa(title, message, icon, msecs); return; } if (!sys)