Skip to content

Commit 88f6d85

Browse files
committed
Update code docs
1 parent 7ce9c33 commit 88f6d85

7 files changed

Lines changed: 41 additions & 5 deletions

docs/components_PersonDetails.bs.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,22 @@
1515
m.extrasGrp.opacity = 1.0
1616
createDialogPallete()
1717
m.top.optionsAvailable = false
18+
19+
' Set initial focus for scene navigation
20+
m.top.lastFocus = m.dscr
1821
end sub
1922

2023
sub OnScreenShown()
2124
' Always set transparent backdrop for person screens
2225
' Prevents stale movie/TV backdrops from persisting
2326
m.global.sceneManager.callFunc("setBackgroundImage", "")
27+
28+
' Restore focus for scene navigation
29+
if isValid(m.top.lastFocus)
30+
m.top.lastFocus.setFocus(true)
31+
else
32+
m.top.setFocus(true)
33+
end if
2434
end sub
2535

2636
sub loadPerson()

docs/components_liveTv_schedule.bs.html

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,15 @@
3232
m.channelIndex = {}
3333
end sub
3434

35+
sub OnScreenShown()
36+
' Restore focus for scene navigation
37+
if isValid(m.top.lastFocus)
38+
m.top.lastFocus.setFocus(true)
39+
else
40+
m.top.setFocus(true)
41+
end if
42+
end sub
43+
3544
sub channelFilterSet()
3645
m.scheduleGrid.jumpToChannel = 0
3746
if isValid(m.top.filter) and m.LoadChannelsTask.filter <> m.top.filter

docs/components_search_SearchResults.bs.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,21 @@
1919

2020
' Observe row item focus for backdrop updates
2121
m.searchSelect.observeField("rowItemFocused", "onSearchItemFocused")
22+
23+
' Set initial focus for scene navigation
24+
m.top.lastFocus = m.top.findNode("SearchBox")
2225
end sub
2326

2427
sub OnScreenShown()
2528
' Start with transparent backdrop - will update on item focus
2629
m.global.sceneManager.callFunc("setBackgroundImage", "")
30+
31+
' Restore focus for scene navigation
32+
if isValid(m.top.lastFocus)
33+
m.top.lastFocus.setFocus(true)
34+
else
35+
m.top.setFocus(true)
36+
end if
2737
end sub
2838

2939
' onSearchItemFocused: Update backdrop when search result is focused

docs/components_tvshows_TVSeasonRow.bs.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
updateSize()
99

1010
m.top.visible = true
11-
m.top.setfocus(true)
1211
end sub
1312

1413
sub updateSize()

docs/components_tvshows_TVShowDetails.bs.html

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
m.overview = m.top.findNode("overview")
2020

2121
m.overview.ellipsisText = tr("... (Press * to read more)")
22+
23+
' Set initial focus for scene navigation
24+
m.top.lastFocus = m.shuffle
2225
end sub
2326

2427
sub OnScreenShown()
@@ -32,6 +35,13 @@
3235
else
3336
m.log.info("cannot set backdropUrl, m.top.itemContent is invalid")
3437
end if
38+
39+
' Restore focus for scene navigation
40+
if isValid(m.top.lastFocus)
41+
m.top.lastFocus.setFocus(true)
42+
else
43+
m.top.setFocus(true)
44+
end if
3545
end sub
3646

3747
sub itemContentChanged()
@@ -84,8 +94,6 @@
8494

8595
setFieldText("overview", itemData.overview)
8696

87-
m.shuffle.visible = true
88-
8997
if type(itemData.RunTimeTicks) = "LongInteger"
9098
setFieldText("runtime", stri(getRuntime()) + " mins")
9199
end if

docs/data/search.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

docs/module-schedule.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)