Bug fix for mouse click