SessionManager: make it work with web activities

Fixes #4611 .

SessionManager now sends a shutdown signal in each logout, shutdown or
reboot.  Apisocket connects to this signal and sends the stop message
to web activities, so they can do cleanup and store.

SessionManager now uses the ShellModel to check if all activities have
been removed.  If not, it tries again after one second for ten times.
After that, it forces shutdown.

SessionManager has been moved completly to the shell.  It was
inheriting a counterpart class in the toolkit, but was the only
consumer of that class.

Journal is a special case.  It will not be destroyed automatically
like other activities.  So we connect it to the SessionManager
shutdown signal too, and destroy it in the callback.
Consider that can be no active activity in views

The previous commit destroys the Journal window in session logout.
Sugar was assuming that there was always one active activity.  But now
it can be None.
Merge branch 'master' of git://github.com/sugarlabs/sugar