[Qt-interest] Clicking a button without window getting focus

Richard Stellingwerff remenic at gmail.com
Wed Jan 18 15:08:24 CET 2012


Hi there,

I have a Qt window that is always-on-top. In this window, there's a button.
When the user presses this button, the app should do things nobody ever
dreamt possible, but the focus must remain with whatever application had
focus. Unfortunately, this focus issue is giving me headaches. Quite
literally, too..

I've tried setting the focusPolicy of the button to Qt::NoFocus, but the
window still gets activated. If needed, I can write platform-dependent
code. Currently I'm targetting Windows, with Linux and OS X support on the
todo list. Biggest priority right now is getting it to work on Windows. Any
pointers would be really appreciated!

Kind regards,
Richard Stellingwerff.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20120118/6355fa02/attachment.html 


More information about the Qt-interest-old mailing list