public MediaPlayer(Liedje liedje, string filename) { InitializeComponent(); DoNotTriggerUpdateEvent = true; selectionPanel.Size = new Size(this.Size.Width, this.Size.Height); fadeinPanel.Size = new Size(0, this.Size.Height); fadeoutPanel.Size = new Size(0, this.Size.Height); currentPanel.Size = new Size(3, this.Size.Height); this.filename = filename; if (filename != "") { lengte = liedje.Lengte; wmp = new AxWMPLib.AxWindowsMediaPlayer(); wmp.CreateControl(); wmp.URL = filename; wmp.PlayStateChange += wmp_PlayStateChange; wmp.Ctlcontrols.stop(); ChangeButtonText("Play"); label3.Text = liedje.Artiest + " / " + liedje.Titel; label4.Text = "0.00 / 0.00"; numericUpDown1.Maximum = (decimal)lengte; numericUpDown2.Maximum = (decimal)lengte; numericUpDown3.Maximum = (decimal)lengte; numericUpDown3.Value = (decimal)lengte; UpdateSelection(); } }
public Fragment(int dummynr) { liedje = new Liedje(); begintijd = new DateTime(1990, 1, 1, 0, 0, 0); eindtijd = new DateTime(1990, 1, 1, 0, 1, 0); fadein = new DateTime(1990, 1, 1, 0, 0, 0); fadeout = new DateTime(1990, 1, 1, 0, 0, 0); FIBinnen = false; FOBinnen = false; nummer = dummynr; }