From 712d38a2be53b415c2635b86e1f539faec0ace19 Mon Sep 17 00:00:00 2001 From: Michael Date: Fri, 28 Apr 2017 20:01:04 -0400 Subject: Final Beta 2.3 adjustments. --- ShiftOS.WinForms/Applications/AudioPlayer.cs | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'ShiftOS.WinForms/Applications/AudioPlayer.cs') diff --git a/ShiftOS.WinForms/Applications/AudioPlayer.cs b/ShiftOS.WinForms/Applications/AudioPlayer.cs index 28e1c56..9940ddd 100644 --- a/ShiftOS.WinForms/Applications/AudioPlayer.cs +++ b/ShiftOS.WinForms/Applications/AudioPlayer.cs @@ -162,20 +162,17 @@ namespace ShiftOS.WinForms.Applications } if (o.PlaybackState == NAudio.Wave.PlaybackState.Stopped) { - if (lbtracks.SelectedIndex < lbtracks.Items.Count - 1) + this.Invoke(new Action(() => { - this.Invoke(new Action(() => + if (lbtracks.SelectedIndex < lbtracks.Items.Count - 1) { lbtracks.SelectedIndex++; - })); - } - else if(loopToolStripMenuItem.Checked == true) - { - this.Invoke(new Action(() => + } + else if (loopToolStripMenuItem.Checked == true) { lbtracks.SelectedIndex = 0; - })); - } + } + })); } }).Start(); } -- cgit v1.2.3