Added mouse event handling to Gui.