Namespace functions

This commit is contained in:
James Nguyen 2017-11-16 18:05:37 -08:00
parent bc9ce2e01b
commit f86ec8005b
11 changed files with 17 additions and 17 deletions

View File

@ -31,7 +31,7 @@
(require 'evil-collection-util) (require 'evil-collection-util)
(defun evil-bookmark-setup () (defun evil-bookmark-setup ()
(+evilify-map (evil-collection-util-evilify-map
bookmark-bmenu-mode-map bookmark-bmenu-mode-map
:mode bookmark-bmenu-mode)) :mode bookmark-bmenu-mode))

View File

@ -31,7 +31,7 @@
(require 'evil) (require 'evil)
(require 'evil-evilified-state) (require 'evil-evilified-state)
(defmacro +evil-set-default-state-for-mode (mode state) (defmacro evil-collection-util-set-initial-state (mode state)
"Set the default STATE for MODE." "Set the default STATE for MODE."
(let* ((mode-str (symbol-name mode)) (let* ((mode-str (symbol-name mode))
(state-str (symbol-name state)) (state-str (symbol-name state))
@ -46,7 +46,7 @@
(evil-normal-state))) (evil-normal-state)))
(advice-add #',mode :after #',defun-name)))) (advice-add #',mode :after #',defun-name))))
(defmacro +evilify-map (map &rest props) (defmacro evil-collection-util-evilify-map (map &rest props)
"`evilified-state-evilify-map' with additional bindings. "`evilified-state-evilify-map' with additional bindings.
This assumes the :bindings key is at the end." This assumes the :bindings key is at the end."
(let ((contains-bindings (plist-get props :bindings))) (let ((contains-bindings (plist-get props :bindings)))

View File

@ -31,7 +31,7 @@
(require 'compile) (require 'compile)
(defun evil-compile-setup () (defun evil-compile-setup ()
(+evilify-map (evil-collection-util-evilify-map
compilation-mode-map compilation-mode-map
:mode compilation-mode :mode compilation-mode
:bindings :bindings

View File

@ -30,7 +30,7 @@
(require 'edebug) (require 'edebug)
(require 'evil-collection-util) (require 'evil-collection-util)
(+evil-set-default-state-for-mode edebug-mode motion) (evil-collection-util-set-initial-state edebug-mode motion)
(defun evil-edebug-setup () (defun evil-edebug-setup ()

View File

@ -33,7 +33,7 @@
(defvar flycheck-error-list-mode-map) (defvar flycheck-error-list-mode-map)
(defun evil-flycheck-setup () (defun evil-flycheck-setup ()
(+evilify-map (evil-collection-util-evilify-map
flycheck-error-list-mode-map flycheck-error-list-mode-map
:mode flycheck-error-list-mode :mode flycheck-error-list-mode
:bindings :bindings

View File

@ -36,11 +36,11 @@
(defvar ggtags-navigation-map) (defvar ggtags-navigation-map)
(defun evil-ggtags-setup () (defun evil-ggtags-setup ()
(+evilify-map (evil-collection-util-evilify-map
ggtags-global-mode-map ggtags-global-mode-map
:mode ggtags-global-mode) :mode ggtags-global-mode)
(+evilify-map (evil-collection-util-evilify-map
ggtags-view-search-history-mode-map ggtags-view-search-history-mode-map
:bindings :bindings
"j" 'ggtags-view-search-history-prev "j" 'ggtags-view-search-history-prev
@ -53,7 +53,7 @@
"e" 'evil-forward-word-end "e" 'evil-forward-word-end
"E" 'evil-forward-WORD-end) "E" 'evil-forward-WORD-end)
(+evilify-map (evil-collection-util-evilify-map
ggtags-view-tag-history-mode-map ggtags-view-tag-history-mode-map
:bindings :bindings
"\C-j" 'next-error-no-select "\C-j" 'next-error-no-select
@ -61,7 +61,7 @@
"e" 'evil-forward-word-end "e" 'evil-forward-word-end
"E" 'evil-forward-WORD-end) "E" 'evil-forward-WORD-end)
(+evilify-map (evil-collection-util-evilify-map
ggtags-view-tag-history-mode-map ggtags-view-tag-history-mode-map
:bindings :bindings
"\C-j" 'next-error-no-select "\C-j" 'next-error-no-select
@ -69,7 +69,7 @@
"e" 'evil-forward-word-end "e" 'evil-forward-word-end
"E" 'evil-forward-WORD-end) "E" 'evil-forward-WORD-end)
(+evilify-map (evil-collection-util-evilify-map
ggtags-navigation-map ggtags-navigation-map
:bindings :bindings
"\C-j" 'next-error "\C-j" 'next-error

View File

@ -31,7 +31,7 @@
(require 'ibuffer) (require 'ibuffer)
(defun evil-ibuffer-setup () (defun evil-ibuffer-setup ()
(+evilify-map (evil-collection-util-evilify-map
ibuffer-mode-map ibuffer-mode-map
:mode ibuffer-mode :mode ibuffer-mode
:bindings :bindings

View File

@ -33,7 +33,7 @@
(defvar p4-basic-mode-map) (defvar p4-basic-mode-map)
(defun evil-p4-setup () (defun evil-p4-setup ()
(+evilify-map (evil-collection-util-evilify-map
p4-basic-mode-map p4-basic-mode-map
:mode p4-basic-mode :mode p4-basic-mode
:bindings :bindings

View File

@ -33,7 +33,7 @@
(defvar pass-mode-map) (defvar pass-mode-map)
(defun evil-pass-setup () (defun evil-pass-setup ()
(+evilify-map (evil-collection-util-evilify-map
pass-mode-map pass-mode-map
:mode pass-mode :mode pass-mode
:bindings :bindings

View File

@ -34,7 +34,7 @@
(defvar slime-inspector-mode-map) (defvar slime-inspector-mode-map)
(defun evil-slime-setup () (defun evil-slime-setup ()
(+evilify-map (evil-collection-util-evilify-map
sldb-mode-map sldb-mode-map
:mode sldb-mode :mode sldb-mode
:bindings :bindings
@ -46,7 +46,7 @@
"gb" 'sldb-break-on-return "gb" 'sldb-break-on-return
"gB" 'sldb-break-with-default-debugger) "gB" 'sldb-break-with-default-debugger)
(+evilify-map (evil-collection-util-evilify-map
slime-inspector-mode-map slime-inspector-mode-map
:mode slime-inspector-mode :mode slime-inspector-mode
:bindings :bindings

View File

@ -34,7 +34,7 @@
;;; Code: ;;; Code:
(defun evil-vlf-setup () (defun evil-vlf-setup ()
(+evilify-map (evil-collection-util-evilify-map
vlf-mode-map vlf-mode-map
:mode vlf-mode :mode vlf-mode
:bindings :bindings