Do not normalize keyevent on romaja keyboard
authorChoe Hwanjin <choe.hwanjin@gmail.com>
Sat, 26 Feb 2011 12:13:38 +0000 (21:13 +0900)
committerChoe Hwanjin <choe.hwanjin@gmail.com>
Sat, 26 Feb 2011 12:13:38 +0000 (21:13 +0900)
Romaja hangul keyboard is not transliteration method. So when the hangul
keyboard is romaja method, we should use the char from the keyevent without
conversion.

src/engine.c

index e067e73..1fd9f62 100644 (file)
@@ -747,8 +747,10 @@ ibus_hangul_engine_process_key_event (IBusEngine     *engine,
        // each key, not the character. We make the keyval from keycode
        // as if the keyboard is US qwerty layout. Then we can assume the
        // keyval represent the position of the each key.
-       if (keymap != NULL)
-           keyval = ibus_keymap_lookup_keysym(keymap, keycode, modifiers);
+       if (strcmp(hangul_keyboard->str, "ro") != 0) {
+           if (keymap != NULL)
+               keyval = ibus_keymap_lookup_keysym(keymap, keycode, modifiers);
+       }
 
         // ignore capslock
         if (modifiers & IBUS_LOCK_MASK) {