Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not pass key events to the drop_list. #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

marmistrz
Copy link
Contributor

This causes the EditText to lose focus while typing, especially on devices with a hardware keyboard.


PR comments:

This change made it possible for me to use QDict on a device with a hardware keyboard :)

More precisely: on a device with a hardware keyboard every key press would result in the text field losing focus and the first item of the drop_list. A workaround was to use the virtual keyboard. However, the issue sometimes also occurred when using the virtual keyboard.

To be honest, I don't understand the purpose of passing they key events to the drop_list. It seems impossible to select any item from the drop_list while typing in the EditText, so it doesn't make much sense to check for drop_list.selectedItemPosition.

Moreover, the whole condition from the if will usually evaluate to true for any key, regardless of the drop list state. Perhaps you meant && instead of ||, but I still don't get your intention.

This causes the EditText to lose focus while typing, especially on devices with a hardware keyboard.
@marmistrz
Copy link
Contributor Author

ping

1 similar comment
@marmistrz
Copy link
Contributor Author

ping

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant