fix compiler warnings, include events and related objects