Sort chats by last updated, like in iMessage app

The code is now more object-oriented to handle this new complexity.
Merge pull request #18 from m1foley/sort_by_updated

Sort chats by last updated, like in iMessage app
New code structure and sort chat like in iMessage App