Re: [AD] MSVC mouse problem (may be a bug?)

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> The problem is that sometimes (didn't got which
> sequence does this) I have in the middle of the main
> screen the mouse pointer. I've tried to make a
> "install_mouse" and hide it, but I have this "phantom"
> mouse appearance, which, if you re-plug the mouse and
> move the pointer, dissapears, but my application is
> standalone-kiosk alike so it's a mess to have to do
> this...

Sure. Could you try the following hack, which is currently the only thing I 
can think of?

-- 
Eric Botcazou
--- /cvs/allegro/src/win/wmouse.c	Wed Jun 11 19:38:14 2003
+++ allegro/src/win/wmouse.c	Mon Oct 27 16:22:10 2003
@@ -455,8 +455,10 @@ int mouse_dinput_grab(void)
  */
 int mouse_set_syscursor(void)
 {
-   if ((mouse_dinput_device && _mouse_on) || (gfx_driver && !gfx_driver->windowed))
+   if ((mouse_dinput_device && _mouse_on) || (gfx_driver && !gfx_driver->windowed)) {
       SetCursor(NULL);
+      PostMessage(allegro_wnd, WM_MOUSEMOVE, 0, 0);
+   }
    else
       SetCursor(LoadCursor(NULL, IDC_ARROW));
 


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/