git-messenger.vim icon indicating copy to clipboard operation
git-messenger.vim copied to clipboard

fix ignore BufEnter and BufLeave events when create popup window

Open Alex-duzhichao opened this issue 2 years ago • 1 comments

After popup window has been created, git-messenager uses noautocmd wincmd p to jump back to the current buffer, which ignores BufEnter and BufLeave events. Some other plugins depends on event BufEnter/BufLeave to take effect normally. So git-messenager should use wincmd p to preserve events.

See issue #65 for details.

Alex-duzhichao avatar Mar 23 '22 15:03 Alex-duzhichao

Did you confirm that this causes no issue? I concern that the following auto commands are unexpectedly triggered by this change.

https://github.com/rhysd/git-messenger.vim/blob/2e67899355f3f631aad6845925e4c2c13546444d/autoload/gitmessenger/popup.vim#L211

https://github.com/rhysd/git-messenger.vim/blob/2e67899355f3f631aad6845925e4c2c13546444d/autoload/gitmessenger.vim#L70

https://github.com/rhysd/git-messenger.vim/blob/2e67899355f3f631aad6845925e4c2c13546444d/autoload/gitmessenger.vim#L65

rhysd avatar Mar 26 '22 17:03 rhysd