604 questions
0
votes
0
answers
145
views
How to wait for the rendering thread to finished in WPF?
I have a scenario like this: I used caliburn.micro as my MVVM framework in .NET 6 platform.
I need to insert a block in the UI when user clicks the add button, and take a screenshot the "newest&...
1
vote
1
answer
175
views
How to set Label text in .net MAUI using M2MQTT from uPLibrary.Networking.M2Mqtt?
I am trying to set the text of a label with the message I get from MQTT. The message also arrives because I can output it in the debug console. I think it is a problem with the UI thread but I have no ...
0
votes
1
answer
91
views
C# Win Forms : Waiting in a loop on the UI with Thread.Sleep does not allow an async Task (not awaited) to execute its code
I am missing an important concept, and I would really appreciate help. I hope I can describe my problem properly, I am new to posting on forums and asking for help.
I have an async task in a Camera ...
1
vote
1
answer
83
views
WinForms application UI thread is help up by fast updating TreeListView
I currently have a WinForms application where I display data in a TreeListView. The data is CAN messages, and it is currently setup to update the treelistview as soon as a new CAN message is detected. ...
1
vote
0
answers
70
views
Android: threads freezing when Runnables contain animations on singleThreadExecutor
I am creating an Idle fighting game through Android Studio Java which requires running a lot of attacking/general combat animations in sequence. I am using ExecutorService instantiated through ...
-1
votes
1
answer
58
views
A large amount of data posts into main thread android app
I have no idea how to solve problem when backend in synchronous way posts in main (UI) Thread a large amount of data (every 20 milliseconds a list of 1000 elements) and you can't change the code of ...
0
votes
1
answer
787
views
How to wait for an element to be visible with time out in WebView2 in .NET 6.0. Specifically how to access UI thread
In .NET 6.0 using WebView2, I'm trying to wait for a period of time to see if an element becomes visible in the DOM (essentially what Selenium WebDriverWait does, but in WebView2).
I think this code ...
0
votes
2
answers
255
views
Alternative to closure-style to execute code in UI thread
From background thread, when UI needs to be updated, it needs to post to DispatchQueue.main using the async(execute:) function, as shown below:
static func executeInUIThread(_ uiThreadFunc: @escaping (...
2
votes
1
answer
113
views
JavaFX avoiding locking UI during long running operations with mixed UI and not UI elements
In JavaFX in my controller after clicking on Play button starting method 'createTTV()' creating nested TreeTableView(This treetableview will be even larger, but I don't want to paste too much ...
0
votes
2
answers
766
views
Serialization of Access to UI Thread in MAUI
I am using the following code to change the text on a label outside of the UI thread.
The text on the label was not what I expected. It took some time to realize what was happening.
string ...
-2
votes
2
answers
343
views
runOnUiThread executes after waiting 30 seconds
I came across an extremely weird behaviour related to code execution on UI thread after server data retrieval.
In onResume, I start a Thread where I wait for some server data fetch to complete and ...
0
votes
1
answer
113
views
How to Guarantee Equivalent Behavior of `await` from `ContinueWith` in both UI and Non-UI Code
I'm in search of the simplest and safest way to fully guarantee the same behavior as await but using Task.ContinueWith, most specifically to ensure that if the original caller is in the UI thread then ...
-1
votes
1
answer
58
views
Understand Threading in Android(Update UI from another thread)
I was trying to understand the threading in android. As we know, we can't update a view from background thread. I was trying to understand with different cases and came across a case below. When I ...
1
vote
1
answer
127
views
WinForm Task.Wait : why is it blocking the UI?
I guess this kind of things should not be done in general, but I would like to understand why this code is getting the UI blocked, not returning from the await taskMain:
using System.Diagnostics;
...
1
vote
0
answers
82
views
Using C++ Builder and the MainUI thread for feedback
I have a simple question about where to use synchronization when communicating with the user through a Main Form in a multi-threaded application.
I've learned that in multi-threaded apps, to give ...