Event.lua 574 B

12345678910111213141516171819202122232425262728
  1. class "Event"
  2. function Event:Event()
  3. if self.__ptr == nil then
  4. self.__ptr = Polycore.Event()
  5. end
  6. end
  7. function Event:getEventCode()
  8. return Polycore.Event_getEventCode(self.__ptr)
  9. end
  10. function Event:setEventCode(eventCode)
  11. return Polycore.Event_setEventCode(self.__ptr, eventCode)
  12. end
  13. function Event:getDispatcher()
  14. return Polycore.Event_getDispatcher(self.__ptr)
  15. end
  16. function Event:setDispatcher(dispatcher)
  17. return Polycore.Event_setDispatcher(self.__ptr, dispatcher.__ptr)
  18. end
  19. function Event:getEventType()
  20. return Polycore.Event_getEventType(self.__ptr)
  21. end