Methods
(static) buildSectionPlan() → {object}
buildSectionPlan: Reads homeSection0-6 settings, returns ordered array of sections to display
Array of { type: string, settingIndex: integer }
- Type:
- object
(static) cleanupLatestMediaTasks() → {void}
cleanupLatestMediaTasks: Stop and unobserve any in-flight latest media tasks
- Type:
- void
(static) createSkeletonRow(sectionType) → {object}
createSkeletonRow: Creates a single empty HomeRow with correct title, sectionId, and cursorSize. Adds a single placeholder child node so the RowList renders the row.
| Name | Type | Description |
|---|---|---|
sectionType | string | The section type from user settings |
HomeRow node, or invalid if section type is unsupported
- Type:
- object
(static) createSkeletonRows() → {void}
createSkeletonRows: Creates empty HomeRow nodes for all planned sections except latestmedia. Each skeleton row gets a single placeholder child so the RowList renders the row label and a loading indicator at the correct slot size.
- Type:
- void
(static) findInsertIndexForSection(sectionId) → {integer}
findInsertIndexForSection: Determines the correct content index for a section that needs to be inserted. Uses the section plan ordering to maintain row order.
| Name | Type | Description |
|---|---|---|
sectionId | string | The sectionId to insert |
Index where the row should be inserted
- Type:
- integer
(static) findLatestMediaInsertIndex() → {integer}
findLatestMediaInsertIndex: Determines the correct content index for latestmedia rows based on the section plan ordering.
Index where latestmedia rows should be inserted
- Type:
- integer
(static) findRowBySectionId(sectionId) → {object}
findRowBySectionId: Find a row in content by its sectionId field
| Name | Type | Description |
|---|---|---|
sectionId | string | The sectionId to search for |
{ row: node, index: integer } or invalid if not found
- Type:
- object
(static) getItemAtIndices(indices) → {dynamic}
Gets an item from content at specified row and item indices Performs all necessary bounds checking and validation
| Name | Type | Description |
|---|---|---|
indices | roArray | [rowIndex, itemIndex] |
ContentNode if valid, invalid otherwise
- Type:
- dynamic
(static) getRowConfigForSection(sectionId) → {object}
getRowConfigForSection: Returns title and slotSize for a sectionId. Used when inserting a row that was previously removed (no skeleton exists).
| Name | Type | Description |
|---|---|---|
sectionId | string | The sectionId |
{ title: string, slotSize: array } or invalid if unknown
- Type:
- object
(static) getSectionIdForType(sectionType) → {dynamic}
getSectionIdForType: Maps a section type string to its sectionId
| Name | Type | Description |
|---|---|---|
sectionType | string | Section type from user settings |
sectionId, or invalid if type is unsupported
- Type:
- dynamic
(static) init() → {void}
- Type:
- void
(static) insertLatestMediaSkeletons() → {void}
insertLatestMediaSkeletons: Creates skeleton rows for each non-excluded library and inserts them at the correct position in the content node.
- Type:
- void
(static) itemSelected() → {void}
- Type:
- void
(static) loadLibraries() → {void}
loadLibraries: Entry point called by Home.bs via callFunc. Builds ordered section plan, creates skeleton rows, then fires data tasks.
- Type:
- void
(static) onDestroy() → {void}
onDestroy: Full teardown releasing all resources before component removal Called by Home.bs onDestroy() before nulling the homeRows reference
- Type:
- void
(static) onItemFocused() → {void}
Observer for rowItemFocused field - delegates to updateBackdropForFocusedItem
- Type:
- void
(static) onKeyEvent(key, press) → {boolean}
| Name | Type | Description |
|---|---|---|
key | string | |
press | boolean |
- Type:
- boolean
(static) onLibrariesLoaded() → {void}
onLibrariesLoaded: Handler when LoadLibrariesTask returns data. Populates the library row, creates latestmedia skeleton rows, then fires latest tasks.
- Type:
- void
(static) onProgramsExpired() → {void}
Fires when JRRowList's progress tick detects at least one expired Program or Recording. Re-runs LoadOnNowTask and/or LoadActiveRecordingsTask to pull fresh data. Loading guards debounce repeated expiry signals while a load is already in flight, and section plan checks avoid wasted requests when the user has disabled the relevant sections.
- Type:
- void
(static) onSectionPopulated() → {void}
onSectionPopulated: Called after each section is populated with data. Signals AppLaunchComplete after 2 sections have loaded.
- Type:
- void
(static) populateLibraryRow() → {void}
populateLibraryRow: Fills the library row with filtered library items. Uses populateRowFromData for consistent in-place update behavior.
- Type:
- void
(static) populateRowFromData(sectionId, itemData) → {void}
populateRowFromData: Unified row population logic used by all update callbacks. Updates the children of the existing row node in place to avoid RowList re-layout and focus disruption. Removes the row if data is empty. If the row doesn't exist but data is available (e.g., a previously empty section now has content on refresh), creates and inserts the row at the correct position.
| Name | Type | Description |
|---|---|---|
sectionId | string | The sectionId of the target row |
itemData | dynamic | Array of content nodes from the task, or invalid/empty |
- Type:
- void
(static) removeRowAtIndex(index) → {void}
removeRowAtIndex: Removes a row at the given index and recalculates sizes
| Name | Type | Description |
|---|---|---|
index | integer | Content child index to remove |
- Type:
- void
(static) setRowItemSize() → {void}
setRowItemSize: Loops through all home sections and sets the correct item sizes, heights, and spacings per row. rowItemSize[i] = slot size [width, posterHeight] — determines focus ring dimensions (poster only, no text). rowHeights[i] = total row height: slot + 90px text area for standard rows; slot-only for library tiles. rowSpacings[i] = gap after each row before the next row label. Must be set for ALL rows because Roku ignores itemSpacing entirely once rowSpacings is assigned (even partially). Standard rows use 60px; My Media uses 78px to partially compensate for its absent text area.
- Type:
- void
(static) startLatestMediaLoads() → {void}
startLatestMediaLoads: Fires LoadItemsTask for each latestmedia library
- Type:
- void
(static) startParallelLoads() → {void}
startParallelLoads: Fires off data tasks for sections that don't need library data. Library-dependent sections (library row, latestmedia) are handled in onLibrariesLoaded.
- Type:
- void
(static) updateActiveRecordingsItems() → {void}
- Type:
- void
(static) updateBackdropForFocusedItem() → {void}
Update backdrop to match currently focused item Handles all validation and edge cases Used by: onItemFocused observer and row update functions after replaceChild
- Type:
- void
(static) updateContinueWatchingItems() → {void}
- Type:
- void
(static) updateHomeRows() → {void}
updateHomeRows: Refresh data for all rows without tearing down the UI. Keeps existing row nodes in place to avoid focus disruption. As fresh data arrives, populateRowFromData updates row children in place.
- Type:
- void
(static) updateLatestItems(msg) → {void}
updateLatestItems: Processes LoadItemsTask content for a latest-in-library row. Uses msg parameter because each library has its own dynamically created task.
| Name | Type | Description |
|---|---|---|
msg | dynamic | roSGNodeEvent from the LoadItemsTask |
- Type:
- void
(static) updateNextUpItems() → {void}
- Type:
- void
(static) updateOnNowItems() → {void}
- Type:
- void
(static) updateSize() → {void}
- Type:
- void