Replies: 3 comments 3 replies
-
|
A way can be with ThreadPool.RegisterWaitForSingleObject Something like : |
Beta Was this translation helpful? Give feedback.
-
|
This should be pretty easy for C++ using coroutines. The two big points to note is that the MainWindow class also derives from std::enable_shared_from_this. This is to stop the window being destroyed while the coroutine is still active. Second, I use |
Beta Was this translation helpful? Give feedback.
-
|
You can refer to https://learn.microsoft.com/en-us/windows/uwp/cpp-and-winrt-apis/concurrency-3#source-code-for-the-completion_source-sample |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
The question might be wierd, but I would like the functionality to wait for a Win32 event handle in the UI thread without blocking UI, just like
MsgWaitForMultipleObjectsEx. Is there such thing in WinUI2/WinUI3?Beta Was this translation helpful? Give feedback.
All reactions