Send a Message
The Message Count
When a message is received and the message box is not open then the count will increment. This the case until a dialog is open. The messages are then set to read and will not be included in the unread message count.
Receive Message and Reply
The message box is opened, the count is cleared and you can reply back!
Multiple Contacts and Dialogs
Here is an example of multiple chat windows. If you navigate to another page the dialogs will be closed and if you have received messages they will show up in the count next to the contacts' names. It is the same case, if you navigate to a page that does not have the Sharepoint Messenger web part, when you return to a page that does, the messages will be waiting for you.