[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/evil-goggles 214fb33c8f 063/225: Re-add :g/:v. Fix disabli
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/evil-goggles 214fb33c8f 063/225: Re-add :g/:v. Fix disabling the mode |
Date: |
Wed, 12 Jan 2022 08:58:44 -0500 (EST) |
branch: elpa/evil-goggles
commit 214fb33c8f20ca7cc8f4fd28e295d1d538a066db
Author: Evgeni Kolev <evgenysw@gmail.com>
Commit: Evgeni Kolev <evgenysw@gmail.com>
Re-add :g/:v. Fix disabling the mode
---
evil-goggles.el | 26 +++++++++++++++++++++++++-
1 file changed, 25 insertions(+), 1 deletion(-)
diff --git a/evil-goggles.el b/evil-goggles.el
index 477fd616a0..65993d293d 100644
--- a/evil-goggles.el
+++ b/evil-goggles.el
@@ -192,6 +192,16 @@ BEG END are the arguments of the original function."
(evil-goggles--funcall-preserve-interactive orig-fun beg end))
(evil-goggles--funcall-preserve-interactive orig-fun beg end))))
+;; ex global
+
+(defun evil-goggles--evil-ex-global-advice (orig-fun beg end pattern command
&optional invert)
+ "Around-advice for function `evil-ex-global'.
+
+ORIG-FUN is the original function.
+BEG END PATTERN COMMAND &OPTIONAL INVERT are the arguments of the original
function."
+ (let* ((evil-goggles--on t)) ;; set to `t' to prevent showing the overlay
+ (evil-goggles--funcall-preserve-interactive orig-fun beg end pattern
command invert)))
+
;; surround
(defcustom evil-goggles-enable-surround t
@@ -268,6 +278,9 @@ COUNT BEG &OPTIONAL END TYPE REGISTER are the arguments of
the original function
(advice-add 'evil-join :around 'evil-goggles--evil-join-advice)
(advice-add 'evil-join-whitespace :around
'evil-goggles--evil-join-advice))
+ ;; make sure :global and :v don't show the goggles overlay
+ (advice-add 'evil-ex-global :around 'evil-goggles--evil-ex-global-advice)
+
;; evil non-core functions
(when evil-goggles-enable-surround
@@ -279,7 +292,18 @@ COUNT BEG &OPTIONAL END TYPE REGISTER are the arguments of
the original function
(when evil-goggles-enable-replace-with-register
(advice-add 'evil-replace-with-register :around
'evil-goggles--evil-replace-with-register-advice)))
(t
- (advice-remove 'evil-delete 'evil-goggles--evil-delete-advice))))
+ (advice-remove 'evil-delete 'evil-goggles--evil-delete-advice)
+ (advice-remove 'evil-indent 'evil-goggles--evil-indent-advice)
+ (advice-remove 'evil-yank 'evil-goggles--evil-yank-advice)
+ (advice-remove 'evil-join 'evil-goggles--evil-join-advice)
+ (advice-remove 'evil-join-whitespace 'evil-goggles--evil-join-advice)
+
+ (advice-remove 'evil-ex-global 'evil-goggles--evil-ex-global-advice)
+
+ ;; evil non-core functions
+ (advice-remove 'evil-surround-region
'evil-goggles--evil-surround-region-advice)
+ (advice-remove 'evil-commentary 'evil-goggles--evil-commentary-advice)
+ (advice-remove 'evil-replace-with-register
'evil-goggles--evil-replace-with-register-advice))))
(provide 'evil-goggles)
- [nongnu] elpa/evil-goggles 8d6fc41234 023/225: Doc strings, (continued)
- [nongnu] elpa/evil-goggles 8d6fc41234 023/225: Doc strings, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 743fd1d96d 027/225: Indent tweak, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 805e20dcde 022/225: Don't show overlay when :global or :vglobal is executed, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles ac3b272cdb 031/225: Reduce byte compiler errors, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles dd9a888516 032/225: Test infrastructure, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 412ed4ce79 035/225: Initial README, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles fd417360a2 038/225: Update README.md, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 6e4d0fab3c 047/225: Add missing :group to custom variable, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles d759e22ba3 062/225: Re-add support for yank, join, commentary, surround, replace with register, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 336f6038a3 066/225: Don't inherit diff-mode's faces by default, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 214fb33c8f 063/225: Re-add :g/:v. Fix disabling the mode,
ELPA Syncer <=
- [nongnu] elpa/evil-goggles 6645070a0c 068/225: Add helper `evil-goggles-use-diff-faces`, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 7f09345024 069/225: Update README, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles c405e0e58f 074/225: Update README, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 10285be578 073/225: Improve doc for on/off custom vars, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 126b9f77aa 076/225: Update README.md, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles d2dfe823d5 077/225: Remove deprecated variable evil-goggles-faces-alist, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles bb49e3a001 078/225: Make travis catch compilation warnings, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 5b9a3af1af 080/225: Make pasting from a register show the goggles overlay, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 3d71c2c24c 081/225: Add support for evil-set-marker, ELPA Syncer, 2022/01/12
- [nongnu] elpa/evil-goggles 2b7331aa62 082/225: Make checkdoc happy, ELPA Syncer, 2022/01/12