Page title

This commit is contained in:
James Barnsley
2016-12-15 12:54:41 +13:00
parent a4f5f25636
commit 22d930cba5
4 changed files with 46 additions and 2 deletions

View File

@ -23,7 +23,6 @@ const UIMiddleware = (function(){
3000
)
// we don't want to stop things happening as usual
next(action)
break
@ -31,7 +30,17 @@ const UIMiddleware = (function(){
store.dispatch(uiActions.createNotification('Added '+action.tracks_uris.length+' tracks to playlist'))
// we don't want to stop things happening as usual
next(action)
break
case 'MOPIDY_STATE':
helpers.setWindowTitle(store.getState().ui.current_track, action.data)
next(action)
break
case 'MOPIDY_CURRENTTLTRACK':
if( action.data && action.data.track ) helpers.setWindowTitle(action.data.track, store.getState().mopidy.play_state)
next(action)
break