开发者

Why does the mouse disappear in DISCL_EXCLUSIVE | DISCL_FOREGROUND mode?

开发者 https://www.devze.com 2022-12-19 14:55 出处:网络
When using DirectInput, why does the mouse cursor completely disappear when you use DISCL_EXCLUSIVE | DISCL_FOREGROUND as your cooperative level?

When using DirectInput, why does the mouse cursor completely disappear when you use DISCL_EXCLUSIVE | DISCL_FOREGROUND as your cooperative level?

mouse->SetCooperativeLevel ( hwnd, DISCL_EXCLUSIVE | DISCL_FOREGROUND ) ;

Even though DirectInput is depr开发者_开发问答ecated, does the very fact the mouse is not even available to WINDOWS mean that you're slightly more responsive and better when using DirectInput (vs RAWINPUT)?


At the time I opened this question I didn't realize that DISCL_EXCLUSIVE | DISCL_FOREGROUND setting in DirectInput really amounts to RIDEV_CAPTUREMOUSE | RIDEV_NOLEGACY for the mouse in RAWINPUT. You can simply call ShowCursor( FALSE ); to hide the cursor then.

0

精彩评论

暂无评论...
验证码 换一张
取 消