From 79619fdcdf503ff6152488ae749f116fd6d061e7 Mon Sep 17 00:00:00 2001 From: Sweidan Omar Date: Thu, 13 Jan 2022 00:15:57 +0000 Subject: [PATCH] git-tfs-id: [http://tfs.userrendszerhaz.hu:8080/tfs/DefaultCollection]$/MediaCube;C32737 --- client/DxPlay/PlayerForm.cs | 38 +++++++++++++++++++++---------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/client/DxPlay/PlayerForm.cs b/client/DxPlay/PlayerForm.cs index b39ed2e3..3a948871 100644 --- a/client/DxPlay/PlayerForm.cs +++ b/client/DxPlay/PlayerForm.cs @@ -387,14 +387,14 @@ namespace DxPlay private void OnRewindMouseDown(object sender, MouseEventArgs e) { buttonDown = true; - do + if (m_play != null && m_play.State == GraphState.Playing) { - if (m_play != null && m_play.State == GraphState.Playing) + do { m_play.Rewind(10); Application.DoEvents(); - } - } while (buttonDown); + } while (buttonDown); + } } private void OnForwardMouseUp(object sender, MouseEventArgs e) @@ -405,14 +405,14 @@ namespace DxPlay private void OnForwardMouseDown(object sender, EventArgs e) { buttonDown = true; - do + if (m_play != null && m_play.State == GraphState.Playing) { - if (m_play != null && m_play.State == GraphState.Playing) + do { m_play.Forward(10); Application.DoEvents(); - } - } while (buttonDown); + } while (buttonDown); + } } private void OnStepBackMouseUp(object sender, MouseEventArgs e) @@ -423,11 +423,14 @@ namespace DxPlay private void OnStepBackMouseDown(object sender, MouseEventArgs e) { buttonDown = true; - do + if (m_play != null) { - m_play.Rewind(1); - Application.DoEvents(); - } while (buttonDown); + do + { + m_play.Rewind(1); + Application.DoEvents(); + } while (buttonDown); + } } private void OnStepForwardMouseUp(object sender, MouseEventArgs e) @@ -438,11 +441,14 @@ namespace DxPlay private void OnStepForwardMouseDown(object sender, EventArgs e) { buttonDown = true; - do + if (m_play != null) { - m_play.Forward(1); - Application.DoEvents(); - } while (buttonDown); + do + { + m_play.Forward(1); + Application.DoEvents(); + } while (buttonDown); + } } private void Rewind() -- 2.54.0