Browse Source

Merge branch 'develop' into fix_2109_menubar_spacing

Charlie Kindel 2 years ago
parent
commit
1b4cd61f84
1 changed files with 5 additions and 2 deletions
  1. 5 2
      Terminal.Gui/Core/MainLoop.cs

+ 5 - 2
Terminal.Gui/Core/MainLoop.cs

@@ -306,9 +306,12 @@ namespace Terminal.Gui {
 
 			Driver.MainIteration ();
 
+			bool runIdle = false;
 			lock (idleHandlersLock) {
-				if (idleHandlers.Count > 0)
-					RunIdle ();
+				runIdle = idleHandlers.Count > 0;
+			}
+			if (runIdle) {
+				RunIdle ();
 			}
 		}