拦截所有WM_MOUSEWHEEL消息消息、WM_MOUSEWHEEL

2023-09-06 18:15:25 作者:不提过往

我一直在寻找通过Windows API,寻找一种方式来拦截所有WM_MOUSESCROLL消息之前,他们打他们的视角消息队列。拦截后,我需要改变一些东西对他们,并将它们发送到不同的[或同一]消息队列。

I've been searching through the Windows API, looking for a way to intercept all WM_MOUSESCROLL messages before they hit their perspective message queues. After intercepting I need to change a few things about them and send them to a different [or the same] message queue.

我需要做的相当有效的,因为它会在一个相当大的应用程序上运行。

I need to do this fairly efficiently as it will be running on top of a fairly large application.

这是我如何能做到这一点任何想法?我还没有找到一种方法。

Any Ideas on how I can achieve this? I've yet to find a way.

推荐答案

您最好的选择是使用的低级别的鼠标事件挂钩。看到这MSKB文章更多信息。

Your best bet is an unmanaged interception using a low level mouse event hook. see this MSKB article for more info.