[Qt-interest] systemtray icon menu on vista
Boudewijn Rempt
boud at valdyas.org
Wed Dec 17 12:11:44 CET 2008
If I have code like this:
connect(m_d->trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)),
SLOT(onActivated(QSystemTrayIcon::ActivationReason)));
...
void SystemTrayIcon::onActivated(QSystemTrayIcon::ActivationReason reason) {
#ifndef Q_WS_MAC
switch(reason) {
case QSystemTrayIcon::DoubleClick:
Plugger::Plugger::instance()->runPlugin("kwekker");
break;
case QSystemTrayIcon::Context:
m_d->trayIconMenu->exec(QCursor::pos());
break;
case QSystemTrayIcon::MiddleClick:
case QSystemTrayIcon::Trigger:
default:
break;
};
#endif
}
On Vista, when Aero is on, the menu isn't drawn, only its shadow. On XP and X11,
everything looks fine.
However, when I do:
switch(reason) {
case QSystemTrayIcon::DoubleClick:
Plugger::Plugger::instance()->runPlugin("kwekker");
break;
case QSystemTrayIcon::Context:
case QSystemTrayIcon::MiddleClick:
case QSystemTrayIcon::Trigger:
default:
break;
};
Everything seems fine. Is this a bug in Qt, or should I just not try to assign
showing the menu to any trigger myself?
Boudewijn
More information about the Qt-interest-old
mailing list