hook up cmd queue to PlaybackManager
This commit is contained in:
+1
-1
@@ -106,7 +106,7 @@ func NewBottomPanel(pm *backend.PlaybackManager, im *backend.ImageManager, contr
|
||||
pm.OnLoopModeChange(bp.AuxControls.SetLoopMode)
|
||||
pm.OnVolumeChange(bp.AuxControls.VolumeControl.SetVolume)
|
||||
bp.AuxControls.VolumeControl.OnSetVolume = func(v int) {
|
||||
_ = pm.SetVolume(v)
|
||||
pm.SetVolume(v)
|
||||
}
|
||||
bp.AuxControls.OnChangeLoopMode(func() {
|
||||
pm.SetNextLoopMode()
|
||||
|
||||
@@ -158,7 +158,7 @@ func (c *Controller) ConnectPlayQueuelistActions(list *widgets.PlayQueueList) {
|
||||
}
|
||||
list.OnAddToPlaylist = c.DoAddTracksToPlaylistWorkflow
|
||||
list.OnPlayItemAt = func(tracknum int) {
|
||||
_ = c.App.PlaybackManager.PlayTrackAt(tracknum)
|
||||
c.App.PlaybackManager.PlayTrackAt(tracknum)
|
||||
}
|
||||
list.OnShowArtistPage = func(artistID string) {
|
||||
c.NavigateTo(ArtistRoute(artistID))
|
||||
|
||||
+3
-3
@@ -241,13 +241,13 @@ func (m *MainWindow) SetupSystemTrayMenu(appName string, fyneApp fyne.App) {
|
||||
if desk, ok := fyneApp.(desktop.App); ok {
|
||||
menu := fyne.NewMenu(appName,
|
||||
fyne.NewMenuItem(fmt.Sprintf("%s/%s", lang.L("Play"), lang.L("Pause")), func() {
|
||||
_ = m.App.PlaybackManager.PlayPause()
|
||||
m.App.PlaybackManager.PlayPause()
|
||||
}),
|
||||
fyne.NewMenuItem(lang.L("Previous"), func() {
|
||||
_ = m.App.PlaybackManager.SeekBackOrPrevious()
|
||||
m.App.PlaybackManager.SeekBackOrPrevious()
|
||||
}),
|
||||
fyne.NewMenuItem(lang.L("Next"), func() {
|
||||
_ = m.App.PlaybackManager.SeekNext()
|
||||
m.App.PlaybackManager.SeekNext()
|
||||
}),
|
||||
fyne.NewMenuItemSeparator(),
|
||||
fyne.NewMenuItem(lang.L("Volume")+" +10%", func() {
|
||||
|
||||
Reference in New Issue
Block a user