Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
4.6.2
-
None
Description
If a QMainWindow calls shows a child non-modal dialog with the Qt::WA_ShowWithoutActivating attribute flag set to true, and that dialog contains a QLineEdit that is given input focus, then hidden and reshown by the parent main window, then the child dialog will be shown with it's QLineEdit cursor blinking as if it had input focus, even though the window is not activated. This can also lead to a situation where there are two input field cursors blinking on two different windows if the Main Window has an input field that had input focus before showing the child dialog. I have attached an example that reproduced this behavior.
To reproduce with example:
Click File->Popup...
Click on the QLineEdit field of the popup dialog to get input focus.
Click on Tab 2 of the Main Window (hides the dialog)
Switch back to Tab 1 via clicking or Ctrl + Tab
Notice how the QLineEdit's cursor is blinking even though the Window is not activated, nor accepting input.
Attachments
Gerrit Reviews
For Gerrit Dashboard: QTBUG-8857 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
372970,2 | QCompleter: QCompleter multiple input edit reset focus | dev | qt/qtbase | Status: NEW | -2 | 0 |