To: vim_dev@googlegroups.com Subject: Patch 8.1.1666 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.1.1666 Problem: Click in popup window scrollbar with border doesn't scroll. Solution: Correct column for the border. (Naruhiko Nishino, closes #4650) Files: src/popupwin.c, src/testdir/test_popupwin.vim, src/testdir/dumps/Test_popupwin_scroll_9.dump *** ../vim-8.1.1665/src/popupwin.c 2019-07-12 16:05:19.822602216 +0200 --- src/popupwin.c 2019-07-12 16:31:03.779537479 +0200 *************** *** 317,323 **** return; if (row >= wp->w_popup_border[0] && row < height - wp->w_popup_border[2] ! && col == popup_width(wp) - 1) { if (row >= height / 2) { --- 317,323 ---- return; if (row >= wp->w_popup_border[0] && row < height - wp->w_popup_border[2] ! && col == popup_width(wp) - wp->w_popup_border[1] - 1) { if (row >= height / 2) { *** ../vim-8.1.1665/src/testdir/test_popupwin.vim 2019-07-12 16:05:19.822602216 +0200 --- src/testdir/test_popupwin.vim 2019-07-12 16:29:38.623925801 +0200 *************** *** 1580,1585 **** --- 1580,1586 ---- call feedkeys("\\", "xt") endfunc func ClickBot() + call popup_setoptions(g:winid, {'border': [], 'close': 'button'}) call feedkeys("\\", "xt") endfunc map :call test_setmouse(5, 36) *** ../vim-8.1.1665/src/testdir/dumps/Test_popupwin_scroll_9.dump 2019-06-29 07:36:05.348264881 +0200 --- src/testdir/dumps/Test_popupwin_scroll_9.dump 2019-07-12 16:29:53.191859268 +0200 *************** *** 1,10 **** >1+0&#ffffff0| @73 |2| @73 ! |3| @73 ! |4| @31|f+0#0000001#ffd7ff255|i|v|e| @3| +0#0000000#ff404010| +0&#ffffff0@32 ! |5| @31|s+0#0000001#ffd7ff255|i|x| @4| +0#0000000#ff404010| +0&#ffffff0@32 ! |6| @31|s+0#0000001#ffd7ff255|e|v|e|n| @2| +0#0000000#4040ff13| +0&#ffffff0@32 ! |7| @31|e+0#0000001#ffd7ff255|i|g|h|t| @2| +0#0000000#4040ff13| +0&#ffffff0@32 ! |8| @73 |9| @73 |:|c|a|l@1| |C|l|i|c|k|B|o|t|(|)| @40|1|,|1| @10|T|o|p| --- 1,10 ---- >1+0&#ffffff0| @73 |2| @73 ! |3| @30|╔+0#0000001#ffd7ff255|═@8|X| +0#0000000#ffffff0@31 ! |4| @30|║+0#0000001#ffd7ff255|f|i|v|e| @3| +0#0000000#ff404010|║+0#0000001#ffd7ff255| +0#0000000#ffffff0@31 ! |5| @30|║+0#0000001#ffd7ff255|s|i|x| @4| +0#0000000#ff404010|║+0#0000001#ffd7ff255| +0#0000000#ffffff0@31 ! |6| @30|║+0#0000001#ffd7ff255|s|e|v|e|n| @2| +0#0000000#4040ff13|║+0#0000001#ffd7ff255| +0#0000000#ffffff0@31 ! |7| @30|║+0#0000001#ffd7ff255|e|i|g|h|t| @2| +0#0000000#4040ff13|║+0#0000001#ffd7ff255| +0#0000000#ffffff0@31 ! |8| @30|╚+0#0000001#ffd7ff255|═@8|╝| +0#0000000#ffffff0@31 |9| @73 |:|c|a|l@1| |C|l|i|c|k|B|o|t|(|)| @40|1|,|1| @10|T|o|p| *** ../vim-8.1.1665/src/version.c 2019-07-12 16:05:19.822602216 +0200 --- src/version.c 2019-07-12 16:31:30.315416735 +0200 *************** *** 779,780 **** --- 779,782 ---- { /* Add new patch number below this line */ + /**/ + 1666, /**/ -- We learn from our mistakes. Politicians don't make mistakes. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///