Skip to content

AfzalivE/MI-Chat

Repository files navigation

MI-Chat Build Status

Get it on Google Play

The Android app uses the Apache v2 license. License text to be added later.

Macinsiders native Android chat app

Messages screen (Phone) Messages screen (Tablet)

Testers

You must be registered on Macinsiders.com to be able to test this app, hence you need to be a McMasterU student.

If you would like to become a beta tester for this app:

  1. Join Macinsiders Chat Testers Google+ community
  2. Click "Become a tester" on this page
  3. Get the app from the Google Play Store page

Note

I have completely removed support for ant build system, using gradle instead. If you still want to build with ant, fork this project and import it to your IDE. From there, you're on your own.

Dependencies

Included as jars

Proposed app workflow

  • User enters credentials and clicks the login button. Login form is posted and PersistentCookieStore is used to save the cookies in a SharedPreference (not sure of security at the moment)

  • PageProcessor.getResource() is called to execute the GET request and a w3c Document is obtained through which a Page object is created.

  • The result is saved in a local database (tables for Info, Users and Messages) using a ContentProvider/Resolver.

  • Using the MessagesCursorAdapter, the messages information is retrieved and the list in MessagesActivity is populated with each message styled using the BBCode information.

  • Using the UserCursorAdapter, the user list information is retrieved and the list in UserListFragment is populated

  • This GET is called every 3 seconds. To conserve battery, it is only done while the user is within the app and the screen is on. The refresh interval increases if the chatroom is not very active.

  • MessageProcessor.postResource() is called to post a message. The response obtained is the same as PageProcessor.getResource() so it is parsed in the same way.