media control: fix video ended event handling