I'm newbie learning socket programming between windows and linux.
In a simple program I'm developing like a game, the air client from windows sends movement commands for a game object to the linux socket.
1. mouseDown: move
2. mouseUp: stop
Now in practice, if I press and hold mouse, then release it after a while, all works ok. If I just click, then the movement starts and never stops before I either repeat as above, or press the stop button separately.
I need a guarantee that if the gap between press and release of the mouse button is some less than a second, no event handler is triggered. Or, the condition is that handlers must work only if there is a delay>1s between mouseDown and mouseUp.
Is such a thing possible with this solution or a better one please?