Possible fix for #1517.
This was the intended behavior for selecting entries in a combo box.

Originally, by Tobias. So not sure if I missed anything important.
Merge pull request #1519 from xiaohutai/bugfix-for-issue-1517

Bugfix for issue #1517