Fix FWNX-921 "Crash when clicking on ... drop down box"

This fix is cherry-picked from commits 8415963 and a22fdaf on the develop
branch, which fixed FWNX-748 "Crash clicking on 'Word Category' drop down
box" and FWNX-908 "Crash closing combo" respectively.

Change-Id: I4f1c46d929aa1522d354ce073b0d106fd5b41e9e