[Prime-cvs] CVS update: prime/uim

Back to archive index

Hiroyuki Komatsu komat****@users*****
2005年 1月 18日 (火) 02:04:52 JST


Index: prime/uim/prime.scm
diff -u prime/uim/prime.scm:1.1.2.16 prime/uim/prime.scm:1.1.2.17
--- prime/uim/prime.scm:1.1.2.16	Wed Jan 12 22:57:15 2005
+++ prime/uim/prime.scm	Tue Jan 18 02:04:52 2005
@@ -64,12 +64,6 @@
 ;; If #t, users can select candidates with pressing a number key.
 (define prime-always-number-selection? #f)
 
-(define prime-engine-command-lookup     "lookup_compact")
-;(define prime-engine-command-lookup-all "lookup_compact")
-(define prime-engine-command-lookup-all "lookup_compact_all")
-;(define prime-engine-command-lookup     "lookup_prefix")
-;(define prime-engine-command-lookup-all "lookup_prefix")
-
 ;; config function
 (define prime-dont-use-numeral-key-to-select-cand
   (lambda ()
@@ -678,15 +672,10 @@
   (lambda (prime-session)
     (prime-engine-conv-convert-internal prime-session "segment_reconvert")))
 
-(define prime-engine-set-context
-  (lambda (prime-context)
-    (if (string=? prime-context "")
-	(prime-engine-reset-context)
-	(prime-engine-send-command (list "set_context" prime-context)))))
+(define prime-engine-context-reset
+  (lambda (prime-session)
+    (prime-engine-send-command (list "context_reset" prime-session))))
 
-(define prime-engine-reset-context
-  (lambda ()
-    (prime-engine-send-command (list "reset_context"))))
 
 ;; session operations
 (define prime-engine-session-start
@@ -1385,8 +1374,6 @@
        ((string=? typing-method "tcode")
 	(prime-dont-use-numeral-key-to-select-cand)
 	(set! prime-mask-pending-preedit? #t)
-	(set! prime-engine-command-lookup     "lookup")
-	(set! prime-engine-command-lookup-all "lookup_all")
 	)
        ))
     ))
@@ -1397,6 +1384,9 @@
 
 (define prime-commit-raw
   (lambda (context)
+    ;; Reset the current prime-context
+    (prime-engine-context-reset (prime-context-session context))
+
     (im-commit-raw context)
     (prime-context-set-last-word! context "")
     (prime-preedit-reset! context)
@@ -1404,6 +1394,9 @@
 
 (define prime-commit-without-learning
   (lambda (context string)
+    ;; Reset the current prime-context
+    (prime-engine-context-reset (prime-context-session context))
+
     (if (prime-context-parent-context context)
 	(prime-commit-to-fund-line context string)
 	(im-commit context string))
Index: prime/uim/ChangeLog
diff -u prime/uim/ChangeLog:1.1.2.15 prime/uim/ChangeLog:1.1.2.16
--- prime/uim/ChangeLog:1.1.2.15	Wed Jan 12 22:57:15 2005
+++ prime/uim/ChangeLog	Tue Jan 18 02:04:52 2005
@@ -1,3 +1,8 @@
+2005-01-18  Hiroyuki Komatsu  <komat****@taiya*****>
+
+	* prime.scm: 
+	Added the function prime-engine-context-reset.
+
 2005-01-12  Hiroyuki Komatsu  <komat****@taiya*****>
 
 	* uim-prime 0.9.3-alpha3-2:


Prime-cvs メーリングリストの案内
Back to archive index