public void SetMedia()
 {
     media = MyResources.Main.PlayingTab.GetMediaPlayer();
     Timer_RaseTime.Start();
     ProgressBar_Volume.Value = media.settings.volume;
     Timer_Loop.Enabled       = true;
 }
        private void RewindProgressBar_MouseUp(object sender, MouseEventArgs e)
        {
            rewinding = false;
            var c   = sender as ProgressBar;
            var len = c.Width;
            var x   = e.Location.X;

            c.Maximum = (int)media.Ctlcontrols.currentItem.duration;
            var val = Convert.ToInt32((x * 1.0 / len) * c.Maximum);

            c.Value = (val > c.Maximum) ? c.Maximum : (val < 0) ? 0 : val;
            media.Ctlcontrols.currentPosition = (x * 1.0 / len) * media.Ctlcontrols.currentItem.duration;
            Timer_RaseTime.Start();
        }