If you have searched 'WPF Dispatcher', you must have known why we should use Dispatcher(System.Windows.Threading.Dispathcer) rather than Thread when we want to change UI properties asynchronously. It's something like UI is manipulated by only one single thread, if you change it in Thread, you'll get Exceptions bluh bluh. But I didn't get any Exception so far.
But when I tried to change my program into Dispatcher-driven mode, I encountered a couple of problems. I settled them, so I'd like to share it here.
First, nearly all UI elements are derived from DispatcherObject, then someUIElement.Dispatcher gets the singleton Dispatcher object. Since my program uses MVVM, I cannot get UIElements easily in ViewModel layer, I use Application.Current.Dispatcher instead eventually.
Then your code should look like this:
public(private) delegate void UpdateViewDelegate(Param1 param1, Param2 param2...);
public(priv