Sign in to follow this  
XTAL256

Getting 2 WM_LBUTTONUP messages on mouse up

Recommended Posts

I just realised that my game is getting 2 WM_LBUTTONDOWN and WM_LBUTTONUP messages every time i press or release the mouse button. I noticed it when i was debugging and saw that a method that was getting called when the game was started was getting called twice. And this was because two consecutive mouse up events were being generated when i clicked the "Start" button. I am using SDL, and my own GUI system, but the messages are coming from Windows. I can see it in Winspector Spy. Two WM_LBUTTONDOWN messages when i press down, then two WM_LBUTTONUP messages when i release. But the funny thing is that when i click any other button it doesn't happen. I don't think i am sending any messages or anything like that, i am not calling SDL_PushEvent. Anyone have any idea what could be causing this?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this