Move mc/maybe-multiple-cursors-mode to core.

This commit is contained in:
Magnar Sveen 2012-11-18 21:10:09 +01:00
parent 839c6ef077
commit 0a081a7c5f
2 changed files with 6 additions and 6 deletions

View File

@ -80,12 +80,6 @@
(mc/cursor-end cursor))))
strings))
(defun mc/maybe-multiple-cursors-mode ()
"Enable multiple-cursors-mode if there is more than one currently active cursor."
(if (> (mc/num-cursors) 1)
(multiple-cursors-mode 1)
(multiple-cursors-mode 0)))
(defvar mc/enclose-search-term nil
"How should mc/mark-more-* search for more matches?

View File

@ -458,6 +458,12 @@ They are temporarily disabled when multiple-cursors are active.")
(add-hook 'after-revert-hook #'(lambda () (multiple-cursors-mode 0)))
(defun mc/maybe-multiple-cursors-mode ()
"Enable multiple-cursors-mode if there is more than one currently active cursor."
(if (> (mc/num-cursors) 1)
(multiple-cursors-mode 1)
(multiple-cursors-mode 0)))
(defmacro unsupported-cmd (cmd msg)
"Adds command to list of unsupported commands and prevents it
from being executed if in multiple-cursors-mode."