Change event constants to be of type EventType rather than untyped integers.