Remote control events in roku

Posted By : Rahul Baboria | 30-Sep-2017

The SceneGraph architecture supports depends on remote control key focus. At any time, any node in the SceneGraph node tree can be assigned the remote key focus. Focus on a node is the most important thing, whenever focus is set on one node, the other one item's focus automatically gets lost. But to bring focus we have to use some methods and to shift focus from the user end we have to play with remote control key events.

Function OnKeyEvent(key, press) as Boolean
    result = false
    if press then
        ? ">>> Browse >> OnkeyEvent"
        if key = "options"
            ' option key handler
        else if key = "back"
			? "back key pressed"
          else if key = "up"
			? "up key pressed"
           else if key = "down"
			? "down key pressed"

            else if key = "left"
			? "left key pressed"

            else if key = "right"
			? "right key pressed"      
        end if
    end if
    return result
End Function

About Author

Author Image
Rahul Baboria

Rahul Baboria is having good knowledge over Android Application.

Request for Proposal

Name is required

Comment is required

Sending message..