Methods
(static) LoadNextSong() → {void}
- Type:
- void
(static) announceAudioNowPlaying() → {object}
Returns the metadata in the response — main.bs's transport dispatcher does the roAppManager call on the MAIN thread (roAppManager isn't creatable on render).
- Type:
- object
(static) applyTheme() → {void}
- Type:
- void
(static) audioNextTrack() → {object}
- Type:
- object
(static) audioPositionChanged() → {void}
- Type:
- void
(static) audioSeekRelative(deltaSeconds) → {object}
| Name | Type | Description |
|---|---|---|
deltaSeconds | integer |
- Type:
- object
(static) audioSeekTo(targetSeconds) → {object}
5s end-slack (vs 30s for video) — songs are short, and we still want the seek to land before the track auto-advances to the next.
| Name | Type | Description |
|---|---|---|
targetSeconds | float |
- Type:
- object
(static) audioStateChanged() → {void}
- Type:
- void
(static) bufferPositionChanged() → {void}
- Type:
- void
(static) endScreenSaver() → {void}
- Type:
- void
(static) exitScrubMode() → {void}
exitScrubMode: Moves player out of scrub mode state, resets back to standard play mode
- Type:
- void
(static) findCurrentSongIndex(songList) → {integer}
| Name | Type | Description |
|---|---|---|
songList | dynamic |
- Type:
- integer
(static) handleAudioVoiceSeek(evt) → {object}
| Name | Type | Description |
|---|---|---|
evt | object |
- Type:
- object
(static) handleTransport(evt) → {object}
handleTransport: Roku voice transport handler. Called from source/main.bs when an roInputEvent with info.type = "transport" arrives and AudioPlayerView is the active scene.
Returns { status: "" } per roInput.EventResponse(). Status codes mirror video.
JellyRock-specific behaviors (audio has no continuous trickplay, no media segments):
- "forward"/"rewind" are discrete 10s seeks.
- "replay" seeks backward by playbackInstantReplaySeconds (same setting as video) — matches the Roku platform spec; users wanting loop control use the "loop" command.
- "skip" advances to the next track.
See https://github.com/rokudev/dev-doc — docs/DEVELOPER/media-playback/voice-controls/transport-controls.md
| Name | Type | Description |
|---|---|---|
evt | object |
- Type:
- object
(static) init() → {void}
- Type:
- void
(static) loadButtons() → {void}
If we have more than 1 song to play, set initial button states
- Type:
- void
(static) loopClicked() → {boolean}
- Type:
- boolean
(static) moveSeekbarThumb(playPositionBarWidth) → {void}
moveSeekbarThumb: Positions the thumb on the seekbar
| Name | Type | Description |
|---|---|---|
playPositionBarWidth | float | width of the play position bar |
- Type:
- void
(static) nextClicked() → {boolean}
Returns false at end-of-queue so callers can distinguish "advanced" from "no-op". Side effects (timestamp reset) only fire when an advance actually happens — pressing Next on the last track is a no-op, not a partial reset.
- Type:
- boolean
(static) onAlbumCoverLoadStatusChanged() → {void}
Toggle the JRPlaceholder behind albumCover based on the real poster's load state. Mirrors the canonical state machine from JRRowItem.bs onPosterLoadStatusChanged, but with itemType statically set to "MusicAlbum" in XML (no per-state retyping).
- Type:
- void
(static) onAudioStreamLoaded() → {void}
- Type:
- void
(static) onButtonSelected() → {void}
Event handler when user selects a button via OK key
- Type:
- void
(static) onDestroy() → {void}
onDestroy: Full teardown releasing all resources before component removal Called automatically by SceneManager.popScene() / clearScenes()
- Type:
- void
(static) onKeyEvent(key, press) → {boolean}
Process key press events
| Name | Type | Description |
|---|---|---|
key | string | |
press | boolean |
- Type:
- boolean
(static) onMetaDataLoaded() → {void}
- Type:
- void
(static) onScreensaverTimeoutLoaded() → {void}
- Type:
- void
(static) pageContentChanged() → {void}
Update values on screen when page content changes
- Type:
- void
(static) playAction() → {boolean}
- Type:
- boolean
(static) previousClicked() → {boolean}
- Type:
- boolean
(static) processScrubAction(seekStep) → {void}
processScrubAction: Handles +/- seeking for the audio trickplay bar
| Name | Type | Description |
|---|---|---|
seekStep | integer | seconds to move the trickplay position (negative values allowed) |
- Type:
- void
(static) resetSeekbarThumb() → {void}
resetSeekbarThumb: Resets the thumb to the playing position
- Type:
- void
(static) screenSaverActive() → {boolean}
- Type:
- boolean
(static) setAudioFavorite(isLike) → {object}
| Name | Type | Description |
|---|---|---|
isLike | boolean |
- Type:
- object
(static) setLoopButtonImage() → {void}
- Type:
- void
(static) setOnScreenTextValues(item) → {void}
Populate on screen text variables
| Name | Type | Description |
|---|---|---|
item | object |
- Type:
- void
(static) setPosterImage(posterURL) → {void}
Set poster image on screen. Empty string clears the URI on both the main album cover and the screensaver cover — the JRPlaceholder behind albumCover surfaces, and the screensaver activator at startScreenSaver() routes to the audio-logo branch instead of drifting a fallback glyph around.
| Name | Type | Description |
|---|---|---|
posterURL | dynamic |
- Type:
- void
(static) setScreenTitle(item) → {void}
Set screen's title text to "Artist / Song" when both are available, just song name if no album artist, or empty string to reset the title.
| Name | Type | Description |
|---|---|---|
item | object |
- Type:
- void
(static) setShuffleIconState() → {void}
- Type:
- void
(static) setTrackNumberDisplay() → {void}
- Type:
- void
(static) setupAnimationTasks() → {void}
- Type:
- void
(static) setupButtons() → {void}
Setup playback buttons, default to Play button selected
- Type:
- void
(static) setupDataTasks() → {void}
Creates tasks to gather data needed to render Scene and play song
- Type:
- void
(static) setupInfoNodes() → {void}
- Type:
- void
(static) setupScreenSaver() → {void}
- Type:
- void
(static) shuffleClicked() → {boolean}
- Type:
- boolean
(static) startScreenSaver() → {void}
- Type:
- void
(static) toggleShuffleEnabled() → {void}
- Type:
- void