Using int for event type, to allow more events for upper-level protocols