mirror of
https://github.com/davidhalter/jedi-vim.git
synced 2025-12-06 18:54:44 +08:00
fix a problem with the quickfix window
This commit is contained in:
@@ -102,14 +102,14 @@ function! jedi#add_goto_window()
|
|||||||
execute 'belowright copen '.g:jedi#quickfix_window_height
|
execute 'belowright copen '.g:jedi#quickfix_window_height
|
||||||
set nolazyredraw
|
set nolazyredraw
|
||||||
if g:jedi#use_tabs_not_buffers == 1
|
if g:jedi#use_tabs_not_buffers == 1
|
||||||
map <buffer> <CR> :call s:goto_window_on_enter()<CR>
|
map <buffer> <CR> :call jedi#goto_window_on_enter()<CR>
|
||||||
endif
|
endif
|
||||||
au WinLeave <buffer> q " automatically leave, if an option is chosen
|
au WinLeave <buffer> q " automatically leave, if an option is chosen
|
||||||
redraw!
|
redraw!
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
function! s:goto_window_on_enter()
|
function! jedi#goto_window_on_enter()
|
||||||
let l:list = getqflist()
|
let l:list = getqflist()
|
||||||
let l:data = l:list[line('.') - 1]
|
let l:data = l:list[line('.') - 1]
|
||||||
if l:data.bufnr
|
if l:data.bufnr
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
source plugin/jedi.vim
|
source plugin/jedi.vim
|
||||||
source test/utils.vim
|
source test/utils.vim
|
||||||
|
|
||||||
@@ -15,4 +14,10 @@ describe 'pyimport'
|
|||||||
Expect g:current_buffer_is_module('subprocess') == 1
|
Expect g:current_buffer_is_module('subprocess') == 1
|
||||||
Expect tabpagenr('$') == 2
|
Expect tabpagenr('$') == 2
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it 'completion'
|
||||||
|
" don't know how to test this.
|
||||||
|
"execute "Pyimport subproc\<Tab>"
|
||||||
|
"Expect g:current_buffer_is_module('subprocess') == 1
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user