Note that there are some explanatory texts on larger screens.

plurals
  1. POIPhone Instant message Client desgin problem
    primarykey
    data
    text
    <p>I am writing an IM Client on iphone.// post ref: #IMClient01. Here is my initial design of it:</p> <pre><code>(UIView*)LogInWindow; // to log in (UITabBarController*) MainTabBarController;//have three tabs, namely:Contacts, Chats, My Profile (UITableViewController*)ContactsController; //manages a list of contact/user (UITableViewController*)ChatsController; //manages a list of chat history, each row is a chat with a different person (UIViewController *)ChatController; //manages a chat/conversation with a single user. </code></pre> <p>As in Skype on IPhone, there are two ways to start a conversation/chat.You can either chat with a Skype user by tapping on the User from Contact or if there is a Chat History associated with the user, you can tap the Chat History in Chats. if the above scenario mapped to my controller classes: If Tapping a cell/row in ContactsController then push ChatController to top view. If Tapping a cell/row in ChatsController then push ChatController to top view.</p> <p>In the two push operations, it would something like:</p> <pre><code>[self.navigationController pushViewController:myChatController animated:YES]; </code></pre> <p>My first question is should myChatController be a singleton class? Unlike on computers,where you can have many chat windows open and each window manages a chat with a different person, in IPhone, there is only one top view/window, so only one chat window can be displayed?</p> <p>My second question: Would this be a good idea if ContactsController and ChatsController each has a ChatController instance variable that points to the same ChatController instance? So when a cell/row in ContactsController or ChatsController is tapped, the same ChatController instance is pushed to the top view to display the conversation?</p> <p>Am I explaining myself clear enough? I would really appreciate if someone can give some suggestions.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload