I've got a program with 2 windows that are open. When I programmatically change the window that's on top, it doesn't have focus.
SecondWindow->raise();
SecondWindow->setFocus();
SecondWindow->raise();
SecondWindow->setFocus();
To copy to clipboard, switch view to plain text mode
The second window comes to the top, but doesn't have focus
Since I'm working in windows if I add
HWND WinHandle = (HWND)SecondWindow->winID();
SetFocus(WinHandle);
HWND WinHandle = (HWND)SecondWindow->winID();
SetFocus(WinHandle);
To copy to clipboard, switch view to plain text mode
It gets focus. Is there a way to do it using strictly Qt?
Bookmarks