Fix #665: Add option to play albums in order on Albums page

This commit is contained in:
Drew Weymouth
2025-08-10 15:06:27 -07:00
parent 43670538b9
commit a317b382ff
5 changed files with 100 additions and 4 deletions
+10
View File
@@ -198,6 +198,16 @@ func NewGridView(iter GridViewIterator, fetch util.ImageFetcher, placeholder fyn
return g
}
// Items returns the items that are currently loaded into the GridView state.
func (g *GridView) Items() []GridViewItemModel {
g.stateMutex.Lock()
defer g.stateMutex.Unlock()
items := make([]GridViewItemModel, len(g.items))
copy(items, g.items)
return items
}
func (g *GridView) SaveToState() *GridViewState {
g.stateMutex.RLock()
s := g.GridViewState