]> git.eshelyaron.com Git - emacs.git/commitdiff
international/mule.el (set-keyboard-coding-system): Recover input meta mode when...
authorKenichi Handa <handa@gnu.org>
Wed, 17 Oct 2012 23:59:24 +0000 (08:59 +0900)
committerKenichi Handa <handa@gnu.org>
Wed, 17 Oct 2012 23:59:24 +0000 (08:59 +0900)
lisp/ChangeLog
lisp/international/mule.el

index 9b1929eae6bbc060b4bf283a7ac5802aef3e66a4..602569156f7e0429c3fbc776099f520831e3d554 100644 (file)
@@ -1,3 +1,9 @@
+2012-10-17  Kenichi Handa  <handa@gnu.org>
+
+       * international/mule.el (set-keyboard-coding-system): Recover
+       input meta mode when the new coding system doesn not use 8-bit.
+       Supply TERMINAL arg to set-input-meta-mode.
+
 2012-10-17  Michael Heerdegen <michael_heerdegen@web.de>  (tiny change)
 
        * wdired.el (wdired-old-marks): New variable.
index e6e3f045a9e77bc98553ad26c62ecf6d21af20c1..922bec64c86accadf9a939e1a22f7c391751c282 100644 (file)
@@ -1355,19 +1355,25 @@ graphical terminals."
                (t
                 (error "Unsupported coding system for keyboard: %s"
                        coding-system)))
-         (when accept-8-bit
-           (or saved-meta-mode
-               (set-terminal-parameter terminal
-                                       'keyboard-coding-saved-meta-mode
-                                       (cons (nth 2 (current-input-mode))
-                                             nil)))
-           (set-input-meta-mode 8))
+         (if accept-8-bit
+             (progn
+               (or saved-meta-mode
+                   (set-terminal-parameter terminal
+                                           'keyboard-coding-saved-meta-mode
+                                           (cons (nth 2 (current-input-mode))
+                                                 nil)))
+               (set-input-meta-mode 8 terminal))
+           (when saved-meta-mode
+             (set-input-meta-mode (car saved-meta-mode) terminal)
+             (set-terminal-parameter terminal
+                                     'keyboard-coding-saved-meta-mode
+                                     nil)))
          ;; Avoid end-of-line conversion.
          (setq coding-system
                (coding-system-change-eol-conversion coding-system 'unix)))
 
       (when saved-meta-mode
-       (set-input-meta-mode (car saved-meta-mode))
+       (set-input-meta-mode (car saved-meta-mode) terminal)
        (set-terminal-parameter terminal
                                'keyboard-coding-saved-meta-mode
                                nil))))