Author: ek.kato
Date: Tue Mar  3 02:42:32 2009
New Revision: 5887

Modified:
   trunk/scm/anthy-utf8.scm
   trunk/scm/anthy.scm
   trunk/scm/social-ime.scm
   trunk/scm/yahoo-jp.scm

Log:
* scm/anthy.scm (anthy-utf8-proc-input-state-with-preedit)
* scm/anthy-utf8.scm (anthy-proc-input-state-with-preedit)
* scm/social-ime.scm (social-ime-proc-input-state-with-preedit)
* scm/yahoo-jp.scm (yahoo-jp-proc-input-state-with-preedit)
  - Reset prediction window which might be forced to raise with
    use-prediciton #f.


Modified: trunk/scm/anthy-utf8.scm
==============================================================================
--- trunk/scm/anthy-utf8.scm    (original)
+++ trunk/scm/anthy-utf8.scm    Tue Mar  3 02:42:32 2009
@@ -1060,6 +1060,8 @@

        ;; backspace
        ((anthy-backspace-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-utf8-reset-prediction-window ac))
        (if (not (rk-backspace rkc))
             (begin
              (ustr-cursor-delete-backside! preconv-str)
@@ -1075,6 +1077,8 @@

        ;; delete
        ((anthy-delete-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-utf8-reset-prediction-window ac))
        (if (not (rk-delete rkc))
             (begin
              (ustr-cursor-delete-frontside! preconv-str)
@@ -1082,11 +1086,15 @@

        ;; kill
        ((anthy-kill-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-utf8-reset-prediction-window ac))
        (ustr-clear-latter! preconv-str)
        (ustr-clear-latter! raw-str))

        ;; kill-backward
        ((anthy-kill-backward-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-utf8-reset-prediction-window ac))
        (rk-flush rkc)
        (ustr-clear-former! preconv-str)
        (ustr-clear-former! raw-str))
@@ -1225,6 +1233,8 @@

        (else   
        ;; handle "n1" sequence as "ん1"
+       (if (not anthy-use-prediction?)
+           (anthy-utf8-reset-prediction-window ac))
        (if (and (not (anthy-utf8-context-alnum ac))
                 (not (ichar-alphabetic? key))
                 (not (string-find

Modified: trunk/scm/anthy.scm
==============================================================================
--- trunk/scm/anthy.scm (original)
+++ trunk/scm/anthy.scm Tue Mar  3 02:42:32 2009
@@ -1055,6 +1055,8 @@

        ;; backspace
        ((anthy-backspace-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-reset-prediction-window ac))
        (if (not (rk-backspace rkc))
             (begin
              (ustr-cursor-delete-backside! preconv-str)
@@ -1070,6 +1072,8 @@

        ;; delete
        ((anthy-delete-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-reset-prediction-window ac))
        (if (not (rk-delete rkc))
             (begin
              (ustr-cursor-delete-frontside! preconv-str)
@@ -1077,11 +1081,15 @@

        ;; kill
        ((anthy-kill-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-reset-prediction-window ac))
        (ustr-clear-latter! preconv-str)
        (ustr-clear-latter! raw-str))

        ;; kill-backward
        ((anthy-kill-backward-key? key key-state)
+       (if (not anthy-use-prediction?)
+           (anthy-reset-prediction-window ac))
        (rk-flush rkc)
        (ustr-clear-former! preconv-str)
        (ustr-clear-former! raw-str))
@@ -1220,6 +1228,8 @@

        (else   
        ;; handle "n1" sequence as "��1"
+       (if (not anthy-use-prediction?)
+           (anthy-reset-prediction-window ac))
        (if (and (not (anthy-context-alnum ac))
                 (not (ichar-alphabetic? key))
                 (not (string-find

Modified: trunk/scm/social-ime.scm
==============================================================================
--- trunk/scm/social-ime.scm    (original)
+++ trunk/scm/social-ime.scm    Tue Mar  3 02:42:32 2009
@@ -1102,6 +1102,8 @@

      ;; backspace
      ((social-ime-backspace-key? key key-state)
+      (if (not social-ime-use-prediction?)
+         (social-ime-reset-prediction-window sc))
       (if (not (rk-backspace rkc))
          (begin
            (ustr-cursor-delete-backside! preconv-str)
@@ -1117,6 +1119,8 @@

      ;; delete
      ((social-ime-delete-key? key key-state)
+      (if (not social-ime-use-prediction?)
+         (social-ime-reset-prediction-window sc))
       (if (not (rk-delete rkc))
          (begin
            (ustr-cursor-delete-frontside! preconv-str)
@@ -1124,11 +1128,15 @@

        ;; kill
      ((social-ime-kill-key? key key-state)
+      (if (not social-ime-use-prediction?)
+         (social-ime-reset-prediction-window sc))
       (ustr-clear-latter! preconv-str)
       (ustr-clear-latter! raw-str))

      ;; kill-backward
      ((social-ime-kill-backward-key? key key-state)
+      (if (not social-ime-use-prediction?)
+         (social-ime-reset-prediction-window sc))
       (rk-flush rkc)
       (ustr-clear-former! preconv-str)
       (ustr-clear-former! raw-str))
@@ -1251,6 +1259,8 @@

      (else
       ;; handle "n1" sequence as "��1"
+      (if (not social-ime-use-prediction?)
+         (social-ime-reset-prediction-window sc))
       (if (and (not (social-ime-context-alnum sc))
               (not (ichar-alphabetic? key))
               (not (string-find

Modified: trunk/scm/yahoo-jp.scm
==============================================================================
--- trunk/scm/yahoo-jp.scm      (original)
+++ trunk/scm/yahoo-jp.scm      Tue Mar  3 02:42:32 2009
@@ -1128,6 +1128,8 @@

      ;; backspace
      ((yahoo-jp-backspace-key? key key-state)
+      (if (not yahoo-jp-use-prediction?)
+         (yahoo-jp-reset-prediction-window yc))
       (if (not (rk-backspace rkc))
          (begin
            (ustr-cursor-delete-backside! preconv-str)
@@ -1143,6 +1145,8 @@

      ;; delete
      ((yahoo-jp-delete-key? key key-state)
+      (if (not yahoo-jp-use-prediction?)
+         (yahoo-jp-reset-prediction-window yc))
       (if (not (rk-delete rkc))
          (begin
            (ustr-cursor-delete-frontside! preconv-str)
@@ -1150,11 +1154,15 @@

        ;; kill
      ((yahoo-jp-kill-key? key key-state)
+      (if (not yahoo-jp-use-prediction?)
+         (yahoo-jp-reset-prediction-window yc))
       (ustr-clear-latter! preconv-str)
       (ustr-clear-latter! raw-str))

      ;; kill-backward
      ((yahoo-jp-kill-backward-key? key key-state)
+      (if (not yahoo-jp-use-prediction?)
+         (yahoo-jp-reset-prediction-window yc))
       (rk-flush rkc)
       (ustr-clear-former! preconv-str)
       (ustr-clear-former! raw-str))
@@ -1277,6 +1285,8 @@

      (else
       ;; handle "n1" sequence as "��1"
+      (if (not yahoo-jp-use-prediction?)
+         (yahoo-jp-reset-prediction-window yc))
       (if (and (not (yahoo-jp-context-alnum yc))
               (not (ichar-alphabetic? key))
               (not (string-find

Reply via email to