Skip to content

Commit

Permalink
Adjust undo-tree commands to lsp-bridge-completion-stop-commands
Browse files Browse the repository at this point in the history
  • Loading branch information
manateelazycat committed Oct 9, 2024
1 parent 5a7185a commit db75a30
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions lsp-bridge.el
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ Setting this to nil or 0 will turn off the heartbeat mechanism."

(defcustom lsp-bridge-completion-stop-commands
'("undo-tree-undo" "undo-tree-redo"
"undo-tree-visualize-redo" "undo-tree-visualize-undo"
"kill-region" "delete-block-backward"
"python-black-buffer" "acm-complete-or-expand-yas-snippet" "acm-insert-number-or-complete-candiate"
"yank" "string-rectangle" "query-replace" "grammatical-edit-unwrap")
Expand Down Expand Up @@ -1559,12 +1560,8 @@ So we build this macro to restore postion after code format."
(defun lsp-bridge--not-follow-complete ()
"Hide completion if last command is `acm-complete'."
(or
(not (member (format "%s" last-command) '("acm-complete"
"acm-complete-quick-access"
"undo-tree-visualize-redo"
"undo-tree-visualize-undo")))
(member (format "%s" this-command) '("self-insert-command"
"org-self-insert-command"))
(not (member (format "%s" last-command) '("acm-complete" "acm-complete-quick-access")))
(member (format "%s" this-command) '("self-insert-command" "org-self-insert-command"))
))

(defun lsp-bridge--not-only-blank-before-cursor ()
Expand Down

0 comments on commit db75a30

Please sign in to comment.