View Single Post
Old 09-17-2008, 04:00 PM   #6 (permalink)
itsnotabigtruck
you lost the game.
zB Programmer
Moderator
Super Zuner
 
itsnotabigtruck's Avatar
 
Join Date: May 2008
Posts: 1,730
Reputation: 740
Awards Showcase
Nurta's Slave Most helpful 
Total Awards: 2
Default

Quote:
Originally Posted by Netrix View Post
You can set the play position to a specific time by doing the following:

Code:
 MediaPlayer.PlayPosition.Subtract(MediaPlayer.PlayPosition + new TimeSpan(x,y,z));
...where x = hours, y = minutes, and z = seconds.

So if you just want to set the play position back to the beginning, all you have to do is this:

Code:
MediaPlayer.PlayPosition.Subtract(MediaPlayer.PlayPosition);

Here is another change:

Code:
Beta:
MediaPlayer.MovePrevious();
MediaPlayer.MoveNext();

CTP:
MediaPlayer.Queue.MovePrevious();
MediaPlayer.Queue.MoveNext();
TimeSpan structs are immutable, so the Subtract function is actually returning a new TimeSpan with the modified result. Flipflopping the track should work though (not sure about the result if it's playing the first or last tracks)
__________________

signature by cloud strife




itsnotabigtruck is offline   Reply With Quote