public PlayList( string dirPath) { this.tracks = new List<Track>(); DirectoryInfo dir = new DirectoryInfo(dirPath); if(dir.GetFiles().Length!=0) { foreach(var file in dir.GetFiles()) { if(file.Extension == ".mp3") { this.tracks.Add(new Track(file.FullName)); } } } if(this.tracks.Count > 0) { this.currentTrack = this.tracks[0]; } }
public void Add(Track track) { tracks.Add(track); }
public void Previus() { this.currentTrack = PreviusTrack; }
public PlayList() { this.tracks = new List<Track>(); this.currentTrack = new Track(); }
public void Next() { this.currentTrack = NextTrack; }