new design for handling mouse events