Close stream when finished (*-player)

This commit is contained in:
Florian Küpper committed 2014-08-09 17:16:51 +02:00
1 parent 4c01396e46
commit 04c2b85e2b
2 files changed
+6

No files matched your search

+4
View File
@@ -106,6 +106,8 @@ namespace VocaluxeLib.Utils.Player
if (song == null)
return;
Close();
_Song = song;
_LoadVideo();
base.Load(Path.Combine(song.Folder, song.MP3FileName), position, autoplay);
@@ -116,6 +118,8 @@ namespace VocaluxeLib.Utils.Player
if (String.IsNullOrEmpty(file))
return;
Close();
_Song = null;
base.Load(file, position, autoplay);
}
+2
View File
@@ -73,6 +73,8 @@ namespace VocaluxeLib.Utils.Player
if (IsPlaying)
Stop();
Close();
_StreamID = CBase.Sound.Load(file, false, true);
if (position > 0f)
Position = position;