[AD] [ alleg-Bugs-3093654 ] ALLEGRO_MOUSE_STATE display property not set (see details)

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


Bugs item #3093654, was opened at 2010-10-23 22:36
Message generated for change (Comment added) made by tjaden
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105665&aid=3093654&group_id=5665

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Windows
Group: 4.9
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Dennis Busch (d_busch)
Assigned to: Nobody/Anonymous (nobody)
Summary: ALLEGRO_MOUSE_STATE display property not set (see details)

Initial Comment:
Observed in Windows with OpenGL display (may or may not be limited to this combination)

To reproduce the bug, do this:
1) create a windowed display using al_create_display
2) call al_install_mouse (it's important for this bug to install the mouse AFTER creating the display)
3) use al_get_mouse_state to fill a state structure
4) when running the programme, make sure you run it in a way that the mouse cursor is initially positioned "inside" the window which will get created
5a) observe how the display property from the state in step 3 is never set (even if you keep polling the state) (until you move the cursor outside of the window and then back inside, then it gets set)
5b) (without performing 5a) use al_set_mouse_xy after step 4 to position the mouse cursor inside the created display and observe that this actually works (positions the mouse inside the display) but when you then call al_get_mouse_state again, observe how the display property of that state is still not set until you  do step 5a)

In summary: if al_install_mouse is called AFTER creating a display and the cursor happens to be inside the created display at the time al_install_mouse is called, the display property of the mouse state never gets set (whereas it should be set to the display in which the mouse is at the time of al_install_mouse) until the mouse is moved outside and back into the display

----------------------------------------------------------------------

>Comment By: Peter Wang (tjaden)
Date: 2010-10-26 21:45

Message:
Fixed on X11. I couldn't reproduce it in wine but I will look on Windows,
too. Don't know about Mac.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105665&aid=3093654&group_id=5665




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