I've noticed that as I tried first to make Layer actually remember current context. Then I realized that current `PathLayer` which I was taking as an example, did not have any state associated with the `Scope` context changes, only with "bigger" Brackets components (e.g. `ProjectManager`). So I made `LanguageLayer` similar to what's been done before without changing much of the communication model.

I think what we need to do is to generalize scope-specific and layer-specific changes. Since they all will react to context, we should have single `contextChanged` notification/method which will be propagated to scopes and further down to the layers. That would help make it clean -- layers will not bring any specific methods related to the context changes that `Scope` will have to adopt.

I cannot think, however, of any good solution to generalize dependency of `ProjectScope` on `ProjectManager` or `LanguageLayer` on changes to the language of the current document. I actually think these being explicit is OK. Or more broadly, in my mind it is ok for  `PreferencesSystem` to depend on (know about) language and project changes. We can make them events, perhaps, as well, but these events will then have to be aware of structure of preferences context (e.g. that there should be `language` or `filename` field).

Is this in line at all with what you're thinking?