added some event controls