Fixes for IME and handling of IME key up/down messages