开发者

Stop GUI Thread from freezing

开发者 https://www.devze.com 2023-02-24 05:31 出处:网络
I have a C# (.NET 4), GUI (WPF) program that uses BackgroundWorker (that calls a \"Parallel.For\" in it)

I have a C# (.NET 4), GUI (WPF) program that uses BackgroundWorker (that calls a "Parallel.For" in it)

and i noticed that the GUI thread is always freezing so that the cores can work on the o开发者_JS百科ther threads.

The GUI Thread has no tasks to perform so that's not the reason I'm experiencing slow GUI.

Thank you


If the UI thread is executing the Parallel.For it will block until all parallel thread have finished their work!

0

精彩评论

暂无评论...
验证码 换一张
取 消