문제

How to handle keydown events for Samsung SmartTV SEF Player (link)?

I tried:

Markup:

<object id="pluginObjectPlayer" border=0 classid="clsid:SAMSUNG-INFOLINK-PLAYER" style="position:absolute;z-index:1;left:0px;top:0px;width:1280px;height:720px"></object>

Code:

var player = document.getElementById('pluginObjectPlayer'); //get player object
player.Play(streamUrl); //start playback
$("body").focus(); //focus on html element which can handle keydown events

Doesn't works. Playback starts normally, but keydown event is not handled.

도움이 되었습니까?

해결책

SEF Player doesn't have any event key handlers, the key event will catched by the scene/main javascript code and need to do the action by code with the player API. For example to stop the playback :

case sf.key.STOP:
player.Stop();
break;
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top