Bug 1041124 - [Messages][Refactoring] Make use of EventDispatcher in MessageManager. r=julien

wondering if a generic "handleEvent" method could be useful. I never liked the enormous handleEvent method we have in some apps, but here the code is quite tidy in each function, so maybe it could be more readable. We could even handle some events with the same code using a input event -> output event mapping.