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

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

[nongnu] elpa/multiple-cursors 37ddaf2 053/434: Set this-command for eac


From: ELPA Syncer
Subject: [nongnu] elpa/multiple-cursors 37ddaf2 053/434: Set this-command for each cursor.
Date: Sat, 7 Aug 2021 09:19:53 -0400 (EDT)

branch: elpa/multiple-cursors
commit 37ddaf2cbe479d5fec5f8a86754f762bcf9d2194
Author: Magnar Sveen <magnars@gmail.com>
Commit: Magnar Sveen <magnars@gmail.com>

    Set this-command for each cursor.
    
     - enables proper interop with delete-selection-mode
---
 multiple-cursors-core.el | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/multiple-cursors-core.el b/multiple-cursors-core.el
index c1295a8..b22b586 100644
--- a/multiple-cursors-core.el
+++ b/multiple-cursors-core.el
@@ -99,8 +99,10 @@ cursor with updated info."
      (mc/for-each-fake-cursor
       (mc/pop-state-from-overlay cursor)
       (ignore-errors
+        (setq this-command cmd)
         (run-hooks 'pre-command-hook)
-        (call-interactively cmd)
+        (unless (eq this-command 'ignore)
+          (call-interactively cmd))
         (when deactivate-mark (deactivate-mark))
         (mc/create-fake-cursor-at-point))))))
 
@@ -189,7 +191,6 @@ from being executed if in multiple-cursors-mode."
 ;; Commands that does not work with multiple-cursors
 (unsupported-cmd isearch-forward ". Feel free to add a compatible version.")
 (unsupported-cmd isearch-backward ". Feel free to add a compatible version.")
-(unsupported-cmd delete-char ", delete-forward-char is preferred for 
interactive use.")
 
 ;; Fixing certain commands
 
;;----------------------------------------------------------------------------------------
@@ -263,7 +264,7 @@ from being executed if in multiple-cursors-mode."
                  subword-downcase
                  backward-kill-word
                  backward-delete-char-untabify
-                 delete-forward-char c-electric-delete-forward
+                 delete-char delete-forward-char c-electric-delete-forward
                  delete-backward-char c-electric-backspace
                  c-electric-paren
                  c-electric-semi&comma



reply via email to

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