Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.2.0
-
None
-
OpenSuSe 13.1
Qt 5.2.0 / QtCreator 3.0
-
-
08ba111719c8c4809e80e1dc8a1956dcfdd9d80d 1567699c0e5681b577ab203274181105d226116c 80d4a19f514f66c4ef2c8b5aa40039fdb6b8dd53
Description
During work on 4.8 --> 5.2 necessitas port of my project i realized some problems with the back button.
I checked two different misbehaviours of the back button on a mainwindow or dialog:
1. The back button doesnt really work at all. The dialog doesnt close ...
2. The back button doesnt close the current dialog on top but the below one. So if you have following dialog stack e.g.: 1. mainwindow, 2. dialog1, 3. dialog2
If you hit the back button in some situation the dialog1 on position 2 is closed and you see the maindow. In some situation with just 2 stack positions it closes the whole app.
In the app with multiple stacks of dialogs at first it doesnt seems to really have a system when the back button works or not. But during playing around i've found a solution to reproduce at least the 1. form of back button misbehavoir (no reaction). Here are the steps to reproduce:
1. Build the "standarddialogs" example
2. Start the app (I've tested this in api10 and api19 emulator)
3. Navigate to FontDialog and hit the QFontDialog::getFont() button
4. Try the back button --> doesnt work for me
5. Tap somewhere in the listwidget
6. Try the back button again--> doesnt work for me
7. Tap into the checkbox "Underlined" and check it
8. Try the back button --> WORKS - dialog closed.
Another Test:
QInputDialog::getInt() --> Hit the button, when the dialog appears just hit the back button --> WORKS - dialog closed
Another VERY interesting Test:
QInputDialog::getItem() --> Hit the button, when the dialog appears just hit the back button --> doesnt work (Maybe interesting the OK button has autofocus) --> NOW hit the TAB button to move the focus to the CANCEL button and hit the back button again --> THIS closes the dialog!
Doing these tests i realized that it seems to has to do with different focus situations. I tried to play around in my app with multiple this->setFocus() in the exec() reimplementation to avoid the below dialog to be closed etc. but it leads to very messy code and it doesnt help to get the back button work in every situation ... so currently the back button behavious is a bit confusing for the users.
Attachments
Issue Links
- is required for
-
QTBUG-37065 Issues to be fixed before 5.3.0 RC1 release
- Closed
- relates to
-
QTBUG-37631 Android: back key event lost because of wrong keyboard visibility
- Closed