Compile with no optimisations, to match the non-native version.
Global shortcuts don't really make sense with Emscripten.
Use a synchronous popup menu for KTextEdit, and ensure it cleans up after itself.