Introduce EventedStorage, used for App#state.

This is basically a hash, but mixes in the Eventable module so
that global state changes are far more easy to listen to than
before (which required access to the target object, e.g. the map
widget needs access to the map window, which is bad). The new
functionality isn’t used yet, but will be soon.
Remove the interdependencies between widgets in favour of the new central event storage in $app.

This is much cleaner than connecting widgets that don’t have to
do something with each other at all.
The test PID is not something related to the main window, but rather to the entire application