Fixed an IE bug on events