Quantcast
Channel: Caliburn.Micro: Xaml Made Easy
Viewing all articles
Browse latest Browse all 1760

New Comment on "The Event Aggregator"

$
0
0
I thought that the whole point of the event aggregator pattern was to decouple listners from publishers. In a proper decoupled system, how does the publisher know if a message should be published on the UI thread, HTTP thread, of any other thread? To me, it makes more sense that a listener should perform the marshaling is a certain thread is required. If an marshalAction isn't provided, one could assume the current thread of the listener (SynchronizationContext.Current.Post()). WinRT has some application life cycle and presentation events that I would like to 'forward' to the system. Some of the events are processed by services (processes running on a background track) and others by the UI ViewModels. These events are published on the background thread and propagated to the rest of the application. I haven't look into Windows 8 development that deep, so it's possible that the whole application is running on the UI thread, but for now I assume it's not..

Viewing all articles
Browse latest Browse all 1760

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>