AddEventHandler source code