Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Search instead for 
Did you mean: 
EnTerr
Level 8

roOneLineDialogEVENT - what's the point of it?

I tried using roOneLineDialog and the documentation for its event says
"roOneLineDialogEvent" wrote:
Sends the roOneLineDialogEvent with the following predicates that indicate its valid event types:
  • isButtonPressed() as Boolean - A button on the screen was selected.

  • GetIndex() as Integer - Returns the ID of the button which was selected (the first parameter to AddButton).

  • isScreenClosed() as Boolean - The screen was closed and is no longer displayed to the user.

Sounds like the dialog supports buttons. In particular it mentions AddButton() - but when i try .addButton(1,""), i get "Member function not found in BrightScript Component". Also it does not respond to Back remote button, nor does it have EnableBackButton().

So now it seems the component does not support buttons. But if that is the case, isButtonPressed() and GetIndex() are useless and documentation is misleading in mentioning AddButton(). Moreover, there is no use to isScreenClosed() either, because the only way that dialog can be closed is by manually invoking .close(). So the existence of roOneLineDialogEvent is pointless - and in addition so are roOneLineDialog.ifSetMessagePort()/ifGetMessagePort().

Am i missing something or there is semantic failure in that component?
0 Kudos
2 Replies
TheEndless
Level 7

Re: roOneLineDialogEVENT - what's the point of it?

Looks like a copy/paste error to me. My bet would be that they copied roMessageDialog and did a find and replace.
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
0 Kudos
EnTerr
Level 8

Re: roOneLineDialogEVENT - what's the point of it?

I see isButtonPressed() and GetIndex() got removed as possible events, the only one remaining is isScreenClosed().
But when does that get invoked? Will there ever be a roOneLineDialogEvent?
0 Kudos