shawn42/gamebox — comment on commit 7b0c9aef78b3b5af6dd89e8229e893b70515f9f2
File:  line 0
By shawn42:

It's the StageManager's job to manage the BackStage, but not to construct it.
If you want to know where an object comes from, it comes from its context. The system is easier to test and more flexible by composing it with single responsibility objects.

What happens tomorrow when BackStage needs to accept Actors and strip off events from InputManager. Instead of having to update the construction code in the middle of StageManager, you can just go update BackStage with one line of code to specify the new dependency.

Feel free to IM me for further discussion.