inactivity detection fixed

If the user is inactive and closes the editor an indicator that shows
activity is sent to the server.