some refactoring of treenumbers, add unread activity count