Results 1 to 7 of 7

Thread: Anyone knows how to enable the play / pause key at the back of Boxee Box?

  1. #1
    Join Date
    Jan 2011
    Posts
    4

    Default Anyone knows how to enable the play / pause key at the back of Boxee Box?

    I am wondering if anyone knows how to enable play / pause key at the back of the Boxee Box Remote and pass the keycodes to a swf. I have a flash based movie player and when I do boxee.setMode(boxee.KEYBOARD_MODE), the flash app does receive arrow key codes, but the play / pause key does not work.

    Any help is appreciated.

  2. #2

    Default

    The swf is probably receiving the codes but has absolutely no idea what to do with it...

    I think there is some stuff about using the javascript to send those commands, but you have to know what you're trying to emulate
    ~Kai
    Website: http://kaiarmstrong.com
    Twitter: @phikai
    Boxee Development: Think One Zero Boxee Development - Feel free to donate here to help support it!
    Twitter: @ThinkOneZero - Support/News/Updates/Statues about Think One Zero Services

  3. #3
    Join Date
    Jan 2011
    Posts
    4

    Default

    In my flash app, the swf does listens and processes key strokes.

    What happened was if I do boxee.setMode(boxee.KEYBOARD_MODE), the swf can receive key events for arrow keys. However, that play / pause key stroke seems to be intercepted by Boxee. This is evident when boxee.setCanPause is set to false - you would see an error like "cannot pause movie" on the screen. When boxee.setCanPause is set to true, the error is gone.

    When boxee.setMode is set to boxee.NORMAL_MODE, the play / pause key still does not seem to send event to swf, instead Boxee just display the media player OSD and just treats the flash app as a video and tries to pause / play it.

  4. #4
    Join Date
    Dec 2010
    Posts
    23

    Default

    You need to write a control script for youre page.

    http://developer.boxee.tv/JavaScript...ontrol_Scripts

    What flash video player are you using ?
    If its flowplayer i have a controlscript for it.

  5. #5
    Join Date
    Jan 2011
    Posts
    4

    Default

    I am already using a control script and am able to set the mode to KEYBOARD_MODE. I am loading a custom Flash application, not just a video player. It has built-in navigation system and video streaming capabilities already. What's missing the ability to pass play / pause keycodes from Boxee to the swf. Actually a simple test reveals that play / pause keybaord events are not passed to the html page at all. There does not seem to be any documented ways to do this in Boxee Python API either...

    Anyhow, thanks for the information ~

  6. #6
    Join Date
    Dec 2010
    Posts
    23

    Default

    This is what i use to get play and pause.


    boxee.onPause = function()
    {
    browser.execute("flowplayer().pause()");
    }

    boxee.onPlay = function()
    {
    browser.execute("flowplayer().play()");
    }

    But flowplayer already has a jsInterface.

  7. #7
    Join Date
    Jan 2011
    Posts
    4

    Default

    Cool .. it works now. Thanks!

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •