[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/ergoemacs-mode 2ae2ebf 294/325: Remove command loop
From: |
Stefan Monnier |
Subject: |
[elpa] externals/ergoemacs-mode 2ae2ebf 294/325: Remove command loop |
Date: |
Sat, 23 Oct 2021 18:49:14 -0400 (EDT) |
branch: externals/ergoemacs-mode
commit 2ae2ebfd799c5c9b4fa10f3e2797ebf6ed25851b
Author: Matthew Fidler <514778+mattfidler@users.noreply.github.com>
Commit: Matthew Fidler <514778+mattfidler@users.noreply.github.com>
Remove command loop
---
ergoemacs-command-loop.el | 35 -----------------------------------
ergoemacs-mode.el | 24 +-----------------------
2 files changed, 1 insertion(+), 58 deletions(-)
diff --git a/ergoemacs-command-loop.el b/ergoemacs-command-loop.el
index ce77486..e7c87e8 100644
--- a/ergoemacs-command-loop.el
+++ b/ergoemacs-command-loop.el
@@ -853,23 +853,6 @@ KEYS is the keys information"
trans
keys)))
-(defvar erogemacs-command--cua-timer nil)
-
-(defvar ergoemacs-command--cua-key-codes
- (list (nth 0 (listify-key-sequence (kbd "C-c")))
- (nth 0 (listify-key-sequence (kbd "C-x"))))
- "Key codes to check against for C-c and C-x")
-
-(defun ergoemacs-command--dispach-cua ()
- "Dispatches the CUA C-x and C-c."
- (when (and ergoemacs-mode-cua-mode)
- (let ((keys (this-single-command-keys)))
- (when (and (= 1 (length keys))
- (memq (aref keys 0) ergoemacs-command--cua-key-codes)
- mark-active)
- (setq unread-command-events (cons 'ergoemacs-timeout
unread-command-events))
- (ergoemacs-command--cua-timer-off)))))
-
(defvar erogemacs-command--echo-timer nil)
(defvar ergoemacs-command--blink-on nil)
(defvar ergoemacs-orig-echo-keystrokes nil)
@@ -877,24 +860,6 @@ KEYS is the keys information"
(defvar ergoemacs-command--timeout-timer nil)
(defvar ergoemacs-command--timeout-keys nil)
-(defvar erogemacs-command--cua-timer nil)
-
-(defun ergoemacs-command--cua-timer-on ()
- "Turn on the cua timer."
- (if (and mark-active ergoemacs-mode-cua-mode)
- (ergoemacs-command--cua-timer-off)
- (setq erogemacs-command--cua-timer
- (run-at-time t ergoemacs-command-loop-blink-rate
#'ergoemacs-command--dispach-cua))))
-
-(defun ergoemacs-command--cua-timer-off ()
- "Turn off the cua timer."
- (when (timerp erogemacs-command--cua-timer)
- (cancel-timer erogemacs-command--cua-timer)))
-
-
-(add-hook 'ergoemacs-post-command-hook #'ergoemacs-command--cua-timer-on)
-(add-hook 'ergoemacs-shutdown-hook #'ergoemacs-command--cua-timer-off)
-
(defvar ergoemacs-this-command-keys-shift-translated nil
"ergoemacs override of shift translation in command loop.")
diff --git a/ergoemacs-mode.el b/ergoemacs-mode.el
index e2aa2ee..e522142 100644
--- a/ergoemacs-mode.el
+++ b/ergoemacs-mode.el
@@ -403,29 +403,12 @@ after initializing ergoemacs-mode.
map)
"The keybinding that is active when the mark is active.")
-
-(defcustom ergoemacs-mode-cua-mode t
- "Use C-c and C-v for copy paste when mark is active."
- :type 'boolean
- :group 'ergoemacs-mode)
-
-
-(defvar ergoemacs-mark-active-cua-keymap (let ((map (make-sparse-keymap)))
- (define-key map (kbd "C-c
<ergoemacs-timeout>") 'ergoemacs-copy-line-or-region)
- (define-key map (kbd "C-x
<ergoemacs-timeout>") 'ergoemacs-cut-line-or-region)
- map)
- "The keybinding that is active when the mark is active.")
-
-
(defvar ergoemacs-override-alist nil
"ErgoEmacs override keymaps.")
(defvar ergoemacs-minor-alist nil
"ErgoEmacs minor mode keymap.")
-(defvar ergoemacs-minor-cua-alist nil
- "ErgoEmacs cua mode keymap.")
-
(declare-function ergoemacs-advice-undefined "ergoemacs-advice")
(defun ergoemacs-setup-override-keymap ()
@@ -433,12 +416,9 @@ after initializing ergoemacs-mode.
(setq ergoemacs-override-alist `((ergoemacs-mode . ,ergoemacs-user-keymap)
(ergoemacs-mode .
,ergoemacs-override-keymap)
(ergoemacs-mode . ,ergoemacs-keymap))
- ergoemacs-minor-alist `(mark-active . ,ergoemacs-mark-active-keymap)
- ergoemacs-minor-cua-alist `(mark-active .
,ergoemacs-mark-active-cua-keymap))
+ ergoemacs-minor-alist `(mark-active . ,ergoemacs-mark-active-keymap))
(add-hook 'emulation-mode-map-alists ergoemacs-override-alist)
(add-hook 'minor-mode-map-alist ergoemacs-minor-alist)
- (when ergoemacs-mode-cua-mode
- (add-hook 'minor-mode-map-alist ergoemacs-minor-cua-alist))
(advice-add 'undefined :around #'ergoemacs-advice-undefined)
(advice-add 'read-key :before #'ergoemacs-advice-read-key))
@@ -446,8 +426,6 @@ after initializing ergoemacs-mode.
"Remove `ergoemacs-mode' keymaps."
(remove-hook 'emulation-mode-map-alists 'ergoemacs-override-alist)
(remove-hook 'minor-mode-map-alist ergoemacs-minor-alist)
- (when ergoemacs-mode-cua-mode
- (remove-hook 'minor-mode-map-alist ergoemacs-minor-cua-alist))
(advice-remove 'undefined #'ergoemacs-advice-undefined)
(advice-remove 'read-key #'ergoemacs-advice-read-key))
- [elpa] externals/ergoemacs-mode f46ac1c 276/325: Fix typo, (continued)
- [elpa] externals/ergoemacs-mode f46ac1c 276/325: Fix typo, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode e81daf4 283/325: Require comit-mode See #505, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode d7b86f6 279/325: Add urgoemacs-redo that requires undo-fu or emacs 28, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 2fcad48 282/325: Allow toggling of ergoemacs-mode-term-raw-mode, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 59c8ab0 285/325: Remove ergoemacs substitute command keys, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 1ef93b5 277/325: Add major modes menu again, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 821a910 287/325: Fix undo-fu, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode d2d29aa 289/325: Another fix for mark-active indent region, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 97623ad 286/325: Remove cua-mode again, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 87fe6ff 292/325: Remove shift C-c and C-x for now, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 2ae2ebf 294/325: Remove command loop,
Stefan Monnier <=
- [elpa] externals/ergoemacs-mode 5689999 299/325: Fix CUA interference, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 9b72665 304/325: Use passthrough for kill-line, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 577997b 310/325: Pull in many more remaps for using Emacs keys, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 0d2d1c6 308/325: Change how sending emacs keys works, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode dc2e1a6 321/325: Bind ergoemacs-M-O for more generic fix, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode ea5a7f5 322/325: Remove compilation mode map (emulation overrides); Fix isearch M-O, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 5692fc1 325/325: Add replacement for `C-h k`, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode e718715 309/325: Add `mark-whole-buffer`, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 465d265 312/325: Merge branch 'passthrough', Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 500a2eb 314/325: Possibly Fix #505 search, Stefan Monnier, 2021/10/23