added unread message count, system tray notifications, and improved handling of reconnecting old connections