From 268d8d5541b12bd0272d7513ffd478d972b3243d Mon Sep 17 00:00:00 2001 From: Travis Nickles Date: Fri, 5 Jul 2019 15:22:57 -0500 Subject: [PATCH] Add wait period while suspending --- DS4Windows/DS4Forms/DS4Form.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/DS4Windows/DS4Forms/DS4Form.cs b/DS4Windows/DS4Forms/DS4Form.cs index 13eee39..ec66be2 100644 --- a/DS4Windows/DS4Forms/DS4Form.cs +++ b/DS4Windows/DS4Forms/DS4Form.cs @@ -583,6 +583,11 @@ namespace DS4Windows.Forms Program.rootHub.suspending = true; this.Invoke((System.Action)(() => BtnStartStop_Clicked())); wasrunning = true; + + while (this.changingService) + { + Thread.SpinWait(500); + } } break;