Improve UI for watch window
Add a WinBar as the whole prompt buffer thing is not that well undersood. Also allow you to delete a watch from any part of the expression result too.
This commit is contained in:
parent
80ba644732
commit
4586aa36ff
2 changed files with 30 additions and 7 deletions
|
|
@ -97,8 +97,18 @@ function! vimspector#GoToFrame() abort
|
|||
py3 _vimspector_session.ExpandFrameOrThread()
|
||||
endfunction
|
||||
|
||||
function! vimspector#AddWatch( expr ) abort
|
||||
py3 _vimspector_session.AddWatch( vim.eval( 'a:expr' ) )
|
||||
function! vimspector#AddWatch( ... ) abort
|
||||
if a:0 == 0
|
||||
let expr = input( 'Enter watch expression: ' )
|
||||
else
|
||||
let expr = a:1
|
||||
endif
|
||||
|
||||
if expr ==# ''
|
||||
return
|
||||
endif
|
||||
|
||||
py3 _vimspector_session.AddWatch( vim.eval( 'expr' ) )
|
||||
endfunction
|
||||
|
||||
function! vimspector#AddWatchPrompt( expr ) abort
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue