unknown-horizons/unknown-horizons — pull request #2296 by dulrich (2014-08-31 21:42:10+00:00)
Title: resolution for missing/wrong status icons at startup (issue #2210)

In order to capture the status icon messages I created a `QueuingMessageBus` and added the property bus to `Message`, so that `AddStatusIcon` could use `QueuingMessageBus` instead of the regular `MessageBus`.

The primary difference in `QueuingMessageBus` is that it queues up messages received if there are no subscribers, then tries resending them when a subscriber is added.

This approach was necessary because `StatusIconManager` is initialized after the buildings, so it was missing their messages to set decommissioned or plague icons. The decommissioned buildings would end up with low productivity icons instead after a few seconds, because that check is run on an interval.