# Path: e3d/events_processing/EventsListenerClass.py
# class EventsListener(object):
#     def __init__(self):
#         """
#         Inherit from this class and implement the desired on*Event methods to respond to event
#         notifications.
#         @rtype : EventsListener
#         """
#         pass
# 
#     def onMouseEvent(self, event):
#         pass
# 
#     def onKeyEvent(self, event):
#         pass
# 
#     def onJoystickEvent(self, event):
#         pass
# 
#     def onWindowEvent(self, event):
#         pass
# 
#     def onCustomEvent(self, event):
#         pass


from sdl2 import SDL_GetKeyboardState, SDL_PumpEvents, SDL_GetKeyFromName, SDL_GetScancodeFromKey
from collections import OrderedDict
from ctypes import ArgumentError
from .EventsListenerClass import EventsListener
from .eventClasses import *



class EventsManager(object):
    def __init__(self):
        self._listeners = OrderedDict()
        self._keysState = SDL_GetKeyboardState(None)
        self._lastX = -1
        self._lastY = -1

    def addListener(self, ID, listener):
        """


        @type listener: e3d.events_processing.EventsListenerClass.EventsListener
        @type ID: str
        """

# Path: e3d/events_processing/EventsListenerClass.py
# class EventsListener(object):
#     def __init__(self):
#         """
#         Inherit from this class and implement the desired on*Event methods to respond to event
#         notifications.
#         @rtype : EventsListener
#         """
#         pass
# 
#     def onMouseEvent(self, event):
#         pass
# 
#     def onKeyEvent(self, event):
#         pass
# 
#     def onJoystickEvent(self, event):
#         pass
# 
#     def onWindowEvent(self, event):
#         pass
# 
#     def onCustomEvent(self, event):
#         pass


# Path: e3d/events_processing/EventsManagerClass.py
from sdl2 import SDL_GetKeyboardState, SDL_PumpEvents, SDL_GetKeyFromName, SDL_GetScancodeFromKey
from collections import OrderedDict
from ctypes import ArgumentError
from .EventsListenerClass import EventsListener
from .eventClasses import *




class EventsManager(object):
    def __init__(self):
        self._listeners = OrderedDict()
        self._keysState = SDL_GetKeyboardState(None)
        self._lastX = -1
        self._lastY = -1

    def addListener(self, ID, listener):
        """


        @type listener: e3d.events_processing.EventsListenerClass.EventsListener
        @type ID: str
        """

        if not issubclass(type(listener), EventsListener) or not isinstance(listener, EventsListener):