[Qt-interest] Problem with QSystemTrayIcon on left click
Scott Aron Bloom
Scott.Bloom at onshorecs.com
Mon Nov 29 19:25:20 CET 2010
What happens if you simply set the menu using setContextMenu
Part of the problem in using you method, is your menu will have a
completely separate focus environment..
And sicne you can probably click on the icon twice raising the menu
twice etc etc.
Scott
-----Original Message-----
From: qt-interest-bounces at trolltech.com
[mailto:qt-interest-bounces at trolltech.com] On Behalf Of Aaron Lewis
Sent: Sunday, November 28, 2010 8:30 PM
To: qt-interest at trolltech.com
Subject: Re: [Qt-interest] Problem with QSystemTrayIcon on left click
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 11/29/2010 02:58 AM, Scott Aron Bloom wrote:
> I have used QSTI many times, and never saw this type of behavior.
Gentoo Linux , Qt 4.7.1
Codes:
A slot dedicated for handling those events:
private slots:
void showOrHide(QSystemTrayIcon::ActivationReason reason) {
trayIcon.contextMenu()->showNormal();
return;
}
And in construct function:
/// TrayIcon is an instance of QSystemTrayIcon
connect(&trayIcon,SIGNAL(activated(QSystemTrayIcon::ActivationReason)),
this,SLOT(showOrHide(QSystemTrayIcon::ActivationReason)));
This bug also exists in KTTSD , but i'm no longer using that.
>
> What platform?
> Can you post code that reproduces it.
>
> Scott
>
> -----Original Message-----
> From: qt-interest-bounces at trolltech.com
> [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Aaron Lewis
> Sent: Sunday, November 28, 2010 3:47 AM
> To: QT Interest List
> Subject: [Qt-interest] Problem with QSystemTrayIcon on left click
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi,
> If did a left click on QSystemTrayIcon , context menu will just
> popup
> at a wrong position ( normally left-top corner ) , but after a right
> click , further left click on it won't cause troubles , it just show
up
> the right position.
>
> How could i get this problem solved , anyone got some ideas ?
>
> Many thanks !
>
> - --
> Best Regards,
> Aaron Lewis - PGP: 0xDFE6C29E ( http://keyserver.veridis.com )
> Finger Print: 9482 448F C7C3 896C 1DFE 7DD3 2492 A7D0 DFE6 C29E
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
- --
Best Regards,
Aaron Lewis - PGP: 0xDFE6C29E ( http://keyserver.veridis.com )
Finger Print: 9482 448F C7C3 896C 1DFE 7DD3 2492 A7D0 DFE6 C29E
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.16 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQIcBAEBAgAGBQJM8yxLAAoJECSSp9Df5sKeT90QAK2rSon4cPksK686Gyr1xZC9
c7svywIaRiHRZLqkH20qtV3cRaPfk4bPMQN3WkZSKdn3Tl6njYUOpMm1k2pww7zD
phfKv5Mnh4euwkGXS+5V8UshUiUk88IMqSiwYSVuoff3WEPkDNhCW6aAJckmRJ4l
hGNaupNZJPyoIHxn/Mw43zundk3+vmcyhs/KCAVITZ7A9CRvEKW8415wYRNB1AGi
meEIJwvjpZrE2qW/s2GVqY2wREQA989TkINh+zNGN71stgAIkvU52iyAa6b1UEGJ
emqtMDkLKT2Lxf9re8ic5qrBUOB6p5TbwaQHliGdxa+PpZbp3rulagznDGAbFD3U
5Bj0yqzQm8bdrcU1MX+Lt34vSA+wWt21YL33YJcuEl+eab1mJg2NvWZrkL1lsy31
DhbRY+dfj8YFAHb+j+gQUgpk3wmaLuemqZqpj6NJxm9aVHqKMWE8nxrKp0NFpxcj
viJHFtiytK6uqBgOK16qBTI+/VohZ2fekue4jMKU+VyZqIGGBF4cxGrmiQOpqXhF
xUh/a+6gatw4bMCQ2Z6ntSwLfQJoxxQ6vsYgEP2E9ZwU9f+nLQuoUaU1YLpOimGq
wWUVkjHfQHk08yDdn2rjCwzRG+Rp39pWUAuBJMqLDV/9F/gM8xiPgrqOayTBP+yy
lbwh80UcQVdmRy+/4yGP
=gyv0
-----END PGP SIGNATURE-----
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest
More information about the Qt-interest-old
mailing list