Changed the event definitions and added UserModes enum