Adding support for setting events