comparison src/testdir/test_popupwin.vim @ 18002:2fdbcecab216 v8.1.1997

patch 8.1.1997: no redraw after a popup window filter is invoked Commit: https://github.com/vim/vim/commit/bcb4c8f9058c17dead61a0a384cb1e09c5fc459b Author: Bram Moolenaar <Bram@vim.org> Date: Sat Sep 7 14:06:52 2019 +0200 patch 8.1.1997: no redraw after a popup window filter is invoked Problem: No redraw after a popup window filter is invoked. Solution: Redraw if needed.
author Bram Moolenaar <Bram@vim.org>
date Sat, 07 Sep 2019 14:15:04 +0200
parents 0dcc2ee838dd
children 56032a704448
comparison
equal deleted inserted replaced
18001:1edd747222f0 18002:2fdbcecab216
2157 endif 2157 endif
2158 if a:key == "k" 2158 if a:key == "k"
2159 call win_execute(a:winid, "call setpos('.', [0, line('.') - 1, 1, 0])") 2159 call win_execute(a:winid, "call setpos('.', [0, line('.') - 1, 1, 0])")
2160 return 1 2160 return 1
2161 endif 2161 endif
2162 if a:key == 'x' 2162 if a:key == ':'
2163 call popup_close(a:winid) 2163 call popup_close(a:winid)
2164 return 1 2164 return 0
2165 endif 2165 endif
2166 return 0 2166 return 0
2167 endfunction 2167 endfunction
2168 call popup_menu(['111', '222', '333', '444', '555', '666', '777', '888', '999'], #{ 2168 call popup_menu(['111', '222', '333', '444', '555', '666', '777', '888', '999'], #{
2169 \ maxheight : 3, 2169 \ maxheight : 3,
2183 call VerifyScreenDump(buf, 'Test_popupwin_menu_filter_3', {}) 2183 call VerifyScreenDump(buf, 'Test_popupwin_menu_filter_3', {})
2184 2184
2185 call term_sendkeys(buf, "0") 2185 call term_sendkeys(buf, "0")
2186 call VerifyScreenDump(buf, 'Test_popupwin_menu_filter_4', {}) 2186 call VerifyScreenDump(buf, 'Test_popupwin_menu_filter_4', {})
2187 2187
2188 call term_sendkeys(buf, "x") 2188 " check that when the popup is closed in the filter the screen is redrawn
2189 call term_sendkeys(buf, ":")
2190 call VerifyScreenDump(buf, 'Test_popupwin_menu_filter_5', {})
2191 call term_sendkeys(buf, "\<CR>")
2189 2192
2190 " clean up 2193 " clean up
2191 call StopVimInTerminal(buf) 2194 call StopVimInTerminal(buf)
2192 call delete('XtestPopupMenuFilter') 2195 call delete('XtestPopupMenuFilter')
2193 endfunc 2196 endfunc