]> Sergey Matveev's repositories - vim-lsp.git/commitdiff
Merge branch 'main' into focus-fix
authorYegappan Lakshmanan <4298407+yegappan@users.noreply.github.com>
Wed, 24 May 2023 03:22:21 +0000 (20:22 -0700)
committerGitHub <noreply@github.com>
Wed, 24 May 2023 03:22:21 +0000 (20:22 -0700)
1  2 
autoload/lsp/diag.vim

index 249ccb9abb886d434d65f82671d8e6cc68301fe8,5304a5f17555c50897c19209651c76a841667c1a..e7aa84bf94f6da4b216eb8f97e5bd682126024e1
@@@ -421,11 -421,11 +421,15 @@@ export def ShowAllDiags(): voi
      return
    endif
  
 +  var save_winid = win_getid()
+   # make the diagnostics error list the active one and open it
+   var LspQfId: number = getbufvar(bufnr(), 'LspQfId', 0)
+   var LspQfNr: number = getloclist(0, {id: LspQfId, nr: 0}).nr
+   exe $':{LspQfNr} lhistory'
    :lopen
 +  if !opt.lspOptions.keepFocusInDiags
 +    save_winid->win_gotoid()
 +  endif
  enddef
  
  # Display the message of 'diag' in a popup window right below the position in