Fix #35 Can not use IME in mac
Revert again for #39