Move mc/mark-more-like-this-extended-keymap defvar location

This commit is contained in:
Laurence Warne 2024-02-13 21:00:51 +00:00
parent 25b0dca82e
commit ba7852f192

View File

@ -31,8 +31,6 @@
(require 'thingatpt) (require 'thingatpt)
(require 'sgml-mode) (require 'sgml-mode)
(defvar mc/mark-more-like-this-extended-keymap (make-sparse-keymap))
(defun mc/cursor-end (cursor) (defun mc/cursor-end (cursor)
(if (overlay-get cursor 'mark-active) (if (overlay-get cursor 'mark-active)
(max (overlay-get cursor 'point) (max (overlay-get cursor 'point)
@ -500,6 +498,13 @@ remove the keymap depends on user input and KEEP-PRED:
(push alist emulation-mode-map-alists)))) (push alist emulation-mode-map-alists))))
(defvar mc/mark-more-like-this-extended-keymap (make-sparse-keymap))
(define-key mc/mark-more-like-this-extended-keymap (kbd "<up>") 'mc/mmlte--up)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<down>") 'mc/mmlte--down)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<left>") 'mc/mmlte--left)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<right>") 'mc/mmlte--right)
;;;###autoload ;;;###autoload
(defun mc/mark-more-like-this-extended () (defun mc/mark-more-like-this-extended ()
"Like mark-more-like-this, but then lets you adjust with arrow keys. "Like mark-more-like-this, but then lets you adjust with arrow keys.
@ -561,11 +566,6 @@ are we working on the next or previous cursors?")
(mc/skip-to-next-like-this)) (mc/skip-to-next-like-this))
(mc/mmlte--message)) (mc/mmlte--message))
(define-key mc/mark-more-like-this-extended-keymap (kbd "<up>") 'mc/mmlte--up)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<down>") 'mc/mmlte--down)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<left>") 'mc/mmlte--left)
(define-key mc/mark-more-like-this-extended-keymap (kbd "<right>") 'mc/mmlte--right)
(defvar mc--restrict-mark-all-to-symbols nil) (defvar mc--restrict-mark-all-to-symbols nil)
;;;###autoload ;;;###autoload