fix event handlers for backwards compatability