Author: sasugaanija
Date: Mon Feb 18 08:29:09 2008
New Revision: 5192
Modified:
trunk/emacs/uim-key.el
trunk/emacs/uim.el
Log:
* emacs/uim-key.el
- (uim-translate-xemacs-keyname): Support Multi_key on XEmacs
- (uim-command-execute): Ditto
- (uim-translate-key): Ditto
* emacs/uim.el
- (uim-process-input): Ditto
Modified: trunk/emacs/uim-key.el
==============================================================================
--- trunk/emacs/uim-key.el (original)
+++ trunk/emacs/uim-key.el Mon Feb 18 08:29:09 2008
@@ -55,6 +55,7 @@
((string= keyname "ESC") "escape")
((string= keyname "DEL") "delete")
((string= keyname "SPC") "space")
+ ((string= keyname "multi-key") "Multi_key")
(t keyname)))
@@ -219,17 +220,16 @@
(setq map (cdr (assq 'uim-mode minor-mode-map-alist)))
(setcdr (assq 'uim-mode minor-mode-map-alist) uim-dummy-map)
- (if (and bind
- (eq bind 'digit-argument))
+ (if (or (and bind
+ (eq bind 'digit-argument))
+ (and uim-xemacs
+ (not (eventp last-command-char))))
(command-execute uim-key-vector)
(command-execute this-command))
(setq last-command this-command)
;;(setq last-command-char (aref uim-key-vector 0))
- (uim-debug (format "* last-command-char is set %s"
- last-command-char))
-
(if uim-xemacs
(handle-post-motion-command))
@@ -630,13 +630,21 @@
(throw 'fmap-loop t))
(setq translated (lookup-key function-key-map input-vector-main))
-
+
(if (and (or (not translated)
(integerp translated))
(boundp 'local-function-key-map))
(setq translated (lookup-key local-function-key-map
input-vector-main)))
-
+
+ (if (and (symbolp translated) (commandp translated))
+ (let ((sf (symbol-function translated)))
+ (if (and (listp sf)
+ (eq 'autoload (nth 0 sf))
+ (or (eq 'keymap (nth 4 sf))
+ (eq 'macro (nth 4 sf))))
+ (load (nth 1 sf)))))
+
(cond ((not translated)
)
@@ -652,7 +660,6 @@
(uim-debug (format "translated is keymap: %s" translated))
(setq map translated)
(throw 'fmap-loop t))
-
((functionp translated)
;; function ... call immediately and use returned value
Modified: trunk/emacs/uim.el
==============================================================================
--- trunk/emacs/uim.el (original)
+++ trunk/emacs/uim.el Mon Feb 18 08:29:09 2008
@@ -937,6 +937,7 @@
(uim-debug (if map "map: YES" "map: NO"))
(cond ((stringp translated)
+ (setq issue t)
(setq uim-translated-key-vector translated)
(setq uim-untranslated-key-vector nil))