Send QEvent::Tooltip to QSystemTrayIcon
QSystemTrayIcon's window should send QEvent::ToolTip to QSystemTrayIcon main class under X11. This patch fixes regression inroduced in Qt 5.0. Change-Id: I81f6d85e13f492e5e7d13dacc44185a511e5085d Task-number: QTBUG-46130 Reviewed-by: Błażej Szczygieł <spaz16@wp.pl> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
This commit is contained in:
parent
07fdfa5598
commit
acc3df2c4e
@ -284,12 +284,6 @@ bool QSystemTrayIcon::isVisible() const
|
|||||||
*/
|
*/
|
||||||
bool QSystemTrayIcon::event(QEvent *e)
|
bool QSystemTrayIcon::event(QEvent *e)
|
||||||
{
|
{
|
||||||
#if defined(Q_DEAD_CODE_FROM_QT4_X11)
|
|
||||||
if (e->type() == QEvent::ToolTip) {
|
|
||||||
Q_D(QSystemTrayIcon);
|
|
||||||
return d->sys->deliverToolTipEvent(e);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
return QObject::event(e);
|
return QObject::event(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -194,6 +194,9 @@ void QSystemTrayIconSys::mouseDoubleClickEvent(QMouseEvent *ev)
|
|||||||
bool QSystemTrayIconSys::event(QEvent *e)
|
bool QSystemTrayIconSys::event(QEvent *e)
|
||||||
{
|
{
|
||||||
switch (e->type()) {
|
switch (e->type()) {
|
||||||
|
case QEvent::ToolTip:
|
||||||
|
QApplication::sendEvent(q, e);
|
||||||
|
break;
|
||||||
#ifndef QT_NO_WHEELEVENT
|
#ifndef QT_NO_WHEELEVENT
|
||||||
case QEvent::Wheel:
|
case QEvent::Wheel:
|
||||||
return QApplication::sendEvent(q, e);
|
return QApplication::sendEvent(q, e);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user