Add eclipselsp jdt:// support for textDocument/definition (#4030)

This patch adds support for opening jdt:// links on "go to definition" requests returned by Java language servers.

Co-authored-by: w0rp <devw0rp@gmail.com>
This commit is contained in:
yoshi1123
2022-03-04 14:03:27 -05:00
committed by GitHub
parent b42153eb17
commit e490e87a60
27 changed files with 322 additions and 147 deletions

View File

@@ -94,7 +94,7 @@ Execute(Server should be notified on save):
\ [
\ [1, 'textDocument/didChange', {
\ 'textDocument': {
\ 'uri': ale#path#ToURI(expand('%:p')),
\ 'uri': ale#path#ToFileURI(expand('%:p')),
\ 'version': g:ale_lsp_next_version_id - 1,
\ },
\ 'contentChanges': [{'text': join(getline(1, '$'), "\n") . "\n"}],
@@ -118,14 +118,14 @@ Execute(Server should be notified on save with didSave is supported by server):
\ [
\ [1, 'textDocument/didChange', {
\ 'textDocument': {
\ 'uri': ale#path#ToURI(expand('%:p')),
\ 'uri': ale#path#ToFileURI(expand('%:p')),
\ 'version': g:ale_lsp_next_version_id - 1,
\ },
\ 'contentChanges': [{'text': join(getline(1, '$'), "\n") . "\n"}],
\ }],
\ [1, 'textDocument/didSave', {
\ 'textDocument': {
\ 'uri': ale#path#ToURI(expand('%:p')),
\ 'uri': ale#path#ToFileURI(expand('%:p')),
\ },
\ }],
\ ],
@@ -138,7 +138,7 @@ Execute(Server should be notified on change):
\ [
\ [1, 'textDocument/didChange', {
\ 'textDocument': {
\ 'uri': ale#path#ToURI(expand('%:p')),
\ 'uri': ale#path#ToFileURI(expand('%:p')),
\ 'version': g:ale_lsp_next_version_id - 1,
\ },
\ 'contentChanges': [{'text': join(getline(1, '$'), "\n") . "\n"}],