emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/pyim 0906e40: * pyim-indicator.el (pyim-indicator-daemo


From: ELPA Syncer
Subject: [elpa] externals/pyim 0906e40: * pyim-indicator.el (pyim-indicator-daemon-function): Run when current-input-method is "pyim".
Date: Mon, 5 Jul 2021 03:57:13 -0400 (EDT)

branch: externals/pyim
commit 0906e40c0b4ca0f5d97ef69c01dacd7ae8133ace
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>

    * pyim-indicator.el (pyim-indicator-daemon-function): Run when 
current-input-method is "pyim".
---
 pyim-indicator.el | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/pyim-indicator.el b/pyim-indicator.el
index 809583a..2c54774 100644
--- a/pyim-indicator.el
+++ b/pyim-indicator.el
@@ -82,11 +82,12 @@ Indicator 用于显示输入法当前输入状态(英文还是中文)。"
 
 (defun pyim-indicator-daemon-function (func)
   "`pyim-indicator-daemon' 内部使用的函数。"
-  (ignore-errors
-    (let ((chinese-input-p
-           (and (functionp func)
-                (funcall func))))
-      (funcall pyim-indicator chinese-input-p))))
+  (when (equal current-input-method "pyim")
+    (ignore-errors
+      (let ((chinese-input-p
+             (and (functionp func)
+                  (funcall func))))
+        (funcall pyim-indicator chinese-input-p)))))
 
 (defun pyim-indicator-default (chinese-input-p)
   "Pyim 默认使用的 indicator, 主要通过光标颜色和 mode-line 来显示输入状态。"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]