event handling is improved