Skip to content

Commit

Permalink
Current track merged from tltrack; Additional backend artwork
Browse files Browse the repository at this point in the history
  • Loading branch information
jaedb committed Nov 17, 2017
1 parent 7aca106 commit 8836b01
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 8 deletions.
Binary file added src/assets/backgrounds/browse-dirble.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/backgrounds/browse-itunes.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/backgrounds/browse-somafm.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/backgrounds/browse-soundcloud.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/assets/backgrounds/browse-spotify.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 11 additions & 7 deletions src/js/components/Modal/EditRadioModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,19 +45,23 @@ export default class EditRadioModal extends React.Component{

addSeed(){
if (this.state.uri == ''){
this.setState({error_message: 'Cannot be empty'})
return null
this.setState({error_message: 'Cannot be empty'});
return null;
}

var seeds = Object.assign([],this.state.seeds)
var uris = this.state.uri.split(',')
var seeds = Object.assign([],this.state.seeds);
var uris = this.state.uri.split(',');

for (var i = 0; i < uris.length; i++){
if (helpers.uriSource(uris[i]) !== 'spotify'){
this.setState({error_message: 'Non-Spotify URIs not supported'});
return;
}
if (seeds.indexOf(uris[i]) > -1){
this.setState({error_message: 'URI already added'})
this.setState({error_message: 'URI already added'});
} else {
seeds.push(uris[i])
this.setState({error_message: null})
seeds.push(uris[i]);
this.setState({error_message: null});
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/js/views/Queue.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ class Queue extends React.Component{
track,
this.props.queue_metadata["tlid_"+track.tlid],
{
playing: (track.tlid == this.props.current_track.tlid)
playing: (this.props.current_track && this.props.current_track.tlid == track.tlid)
}
);
tracks[i] = track;
Expand Down
16 changes: 16 additions & 0 deletions src/js/views/library/LibraryBrowse.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,10 @@ class LibraryBrowse extends React.Component{
var directory = this.props.directory[i]

switch (directory.name){
case 'Dirble':
directory.icons = ['assets/backgrounds/browse-dirble.jpg']
break

case 'Files':
directory.icons = ['assets/backgrounds/browse-folders.jpg']
break
Expand All @@ -167,6 +171,18 @@ class LibraryBrowse extends React.Component{
directory.icons = ['assets/backgrounds/browse-tunein.jpg']
break

case 'SoundCloud':
directory.icons = ['assets/backgrounds/browse-soundcloud.jpg']
break

case 'iTunes Store: Podcasts':
directory.icons = ['assets/backgrounds/browse-itunes.jpg']
break

case 'Soma FM':
directory.icons = ['assets/backgrounds/browse-somafm.jpg']
break

default:
directory.icons = ['assets/backgrounds/browse-default.jpg']
}
Expand Down

0 comments on commit 8836b01

Please sign in to comment.