注册鼠标滚轮快捷键 - RegisterMouseWheel
函数简介
注册鼠标滚轮快捷键监听,可监听滚动方向及滚动量
注册鼠标快捷键监听前需要调用StartHotkeyHook安装键盘鼠标钩子
回调函数 void MouseWheelCallback(int x, int y, int amount, int rotation) 参数定义
- x 鼠标X坐标
- y 鼠标Y坐标
- amount 滚动量
- rotation 滚动方向
参考windows函数 SetWindowsHookExW 实现
接口名称
RegisterMouseWheel
DLL调用
int RegisterMouseWheel(long ola ,MouseWheelCallback callback)
参数定义:
ola
(长整型数): OLAPlug对象的指针,由 CreateCOLAPlugInterFace 接口生成。callback
回调函数 void MouseWheelCallback(int x, int y, int amount, int rotation)- x 鼠标X坐标
- y 鼠标Y坐标
- amount 滚动量
- rotation 滚动方向
返回值
注册监听状态
整型数:
1 : 成功
0 : 失败