On 07-May-2022 21:26, Bram Moolenaar wrote:
Patch 8.2.4902
Problem:    Mouse wheel scrolling is inconsistent.
Solution:   Use the MS-Winows system setting. (closes #10368)
Files:      runtime/doc/scroll.txt, src/gui_w32.c, src/mouse.c,
             src/proto/mouse.pro, src/testing.c, src/testdir/test_gui.vim


After this patch, mingw64 (gcc 11.3.0) throws this compile warning:
<snip>
gcc -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -march=native -Wall -O3 -fomit-frame-pointer -freg-struct-return -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD gui_w32.c -o gobjnative/gui_w32.o gui_w32.c:4008:12: warning: 'mouse_scroll_chars' defined but not used [-Wunused-variable]
 4008 | static int mouse_scroll_chars = 0;
      |            ^~~~~~~~~~~~~~~~~~
gui_w32.c:4007:12: warning: 'mouse_scroll_lines' defined but not used [-Wunused-variable]
 4007 | static int mouse_scroll_lines = 0;
      |            ^~~~~~~~~~~~~~~~~~
</snip>

The attached patch seems to fix it.

Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/dca04564-19db-e1cb-0f56-bef88091c893%40internode.on.net.
--- gui_w32.c.orig      2022-05-08 06:48:49.682886000 +1000
+++ gui_w32.c   2022-05-09 06:25:38.072099800 +1000
@@ -4003,10 +4003,6 @@
 
 static int dialog_default_button = -1;
 
-// Intellimouse support
-static int mouse_scroll_lines = 0;
-static int mouse_scroll_chars = 0;
-
 #ifdef FEAT_TOOLBAR
 static void initialise_toolbar(void);
 static void update_toolbar_size(void);

Raspunde prin e-mail lui