]> Sergey Matveev's repositories - vim-lsp.git/commitdiff
fix hover popup-filter, remove redundant code
authorSong-Tianxiang <149415622+Song-Tianxiang@users.noreply.github.com>
Tue, 16 Jan 2024 05:59:47 +0000 (13:59 +0800)
committerGitHub <noreply@github.com>
Tue, 16 Jan 2024 05:59:47 +0000 (13:59 +0800)
The original few lines of code are redundant.
Just return false and let vim handle the other keys.
The redundant code disabled mouse scrolling, and the popup will be closed automatically after some seconds (I don't know why it is closed automatically)

autoload/lsp/hover.vim

index 16f3835218298504938c28cc71b752bf590f4baf..1aaddf90085f9898f5d3d45a7d0a031db1448bf8 100644 (file)
@@ -90,11 +90,6 @@ def HoverWinFilterKey(hoverWin: number, key: string): bool
     keyHandled = true
   endif
 
-  if !keyHandled
-    # For any other key, close the hover window
-    hoverWin->popup_close()
-  endif
-
   return keyHandled
 enddef