My best guess would be adding an additional code to the course which would force the device to close the video. Using a quick search on Google I wasn't able to find anything on Apple's Developer website or any javascript code pages. It may be an unsupported task....