I recently started a project in java using a library JSFML. My code snippet is as follows:
Iterable<Event> events;
events = mRenderWindow.pollEvents();
mKeyboardListener.handleEvents(events);
mMouseListener.handleEvents(events);
My problem is that when I use it first KeyboardListener, then it MouseListenerdoesn’t work and vice versa. Can anyone explain this behavior? I was looking for some information, and explanations are not enough.
source
share