flushGraphics ( com.codename1.ui.geom.Rectangle rect ) : void |
int counter = 0; while (renderingOperations.Count() > 0) { try { global::System.Threading.Tasks.Task.Run(() => global::System.Threading.Tasks.Task.Delay(global::System.TimeSpan.FromMilliseconds(5))).ConfigureAwait(false).GetAwaiter().GetResult(); // don't let the EDT die here counter++; if (counter > 10) { Debug.WriteLine("Flush graphics timed out!!!"); return; } } catch (System.Exception e) { global::System.Diagnostics.Debug.WriteLine(e); } } |
|