How to let the chatMessageCell appear in DialogVC programmatically (Not StoryBoard) - sinch

I have gotten the program to send messages as Parse proves that. However i am not using storyboard & do not know display the textMessages in the Dialog view. How can i achieve displaying the textMessage in the dialog view with the same Cell you produced in Storyboard?
I am referring about the iOS tutorial for Parse-Sinch Chat messaging Application called MiniChat.
Thank you!

if you create your view controller with a xib file, copy the code from the chat view and you should be fine. The story board only makes it easier to do navigation.

Related

In Xcode, how do I create an outlet for a button that is inside a container?

I'm a total newbie with xcode and swift, trying to wrap my head around ios programming.
I'm designing a storyboard for my app. The storyboard uses containers to keep track of the controls. In one of the containers resides a button. I want to create an outlet for it to add some code when it is clicked.
If the button would be on the base viewport of the storyboard, I would control-drag a blue line from the button to the source window with my UIViewController subclass file, and it would assist me in generating the code. But for some reason when the button is in a container, this just doesn't work.
When following the documentation, it says to open the assistant editor when the button is selected and it should open the relevant file. So it open an objective-c file, but when I try to control-drag into it, it informs me that I do not have write permissions. Also I feel like I should be doing it in a subclass instead.
I have searched online a lot and tried everything I can think about, but nothing has worked so far. How does this work? Can I do it programmatically or so perhaps? I hope someone can straighten out this question mark...
A container view is intended to represent an area that will host a view from a different view controller that becomes a child of the view controller that owns the container. Usually, you would create a second view controller, link your container view to it using an "embed" segue, and then put your buttons and such in the second controller's view. The code behind those would then go into the second controller.
If your purpose is simply to have superviews to control layout within a single view controller, use a UIView rather than a container and the problem goes away. That's what the Editor->Embed In->View menu item is for.

iOS 7 Back Button in Interface builder

I've been messing around with the new iOS7 SDK and I want to make a back button like there is in most of the other OS apps. Heres a screen shot of what I'm trying to do:
But I can't figure out how. I've never really messed with interface builder because I usually code with opengl apps, so any solutions would be much appreciated. Thanks.
That is is standard "back" button. You get this when you use a navigation controller and show one view controller then push a second. The "<" means "go back". The "September" part is the title of the previous view controller. You don't need to create one of these. Just make proper use of a navigation controller and a couple of view controllers and it will appear automatically.

Should a non-document based app use an application modal dialog or sheet?

I have a single window based cocoa application. It does not have any documents etc. Essentially it is a utility app. I need to show a modal dialog box, basically a connection box to which has an ip, port, connect controls.
I read somewhere that modal dialogs are not recommended in cocoa based apps. Is that correct ? So should I use document based dialog ? I am quite confused about it, any guidance on that subject would be appreciated.
Modal dialogs can get lost in presentation (showing up on the wrong desktop/space, full screen issues, etc). Sheets tie into the window, so they always display properly.
Full guidance is available in the Human Interface Guidelines https://developer.apple.com/library/mac/#documentation/UserExperience/Conceptual/AppleHIGuidelines/Windows/Windows.html#//apple_ref/doc/uid/20000961-TP9

How Do I Connect A UITabBarController To The App Delegate In A View-Based App (Part 1)?

I'm attempting to convert my view based application to a tab bar application. I'm having trouble connecting a new UITabBarController to the App Delegate. It doesn't give me the option. I must be missing some sort of connection along the way.
I added a Tab Bar Controller to my "MainViewController.xib". From most of the things I've read, I should be connecting to the "MainWindow.xib," only problem is that I've got both iPhone and iPad formats setup from the View-Based Application so I'm looking for a way to connect it universally (so I don't have to recreate it for both the iPhone and iPad formats separately).
I created an outlet in my MillersAppAppDelegate.h file (and synthesized it all correctly) but the outlet that I created for the Tab Bar Controller does not appear as an option when I attempt to connect it in the Interface Builder (I'm assuming this is because I haven't correctly connecting the Tab Bar Controller to the delegate in the first place).
I'd like to just stop here and learn this first step so it doesn't get too confusing yet:
1) How do I connect my new Tab Bar Controller to the App Delegate in a View-Based App?
2) How do I then subsequently connect my Tab Bar Controller (that was created and synthesized in the App Delegate) to the UITabBarController?
I've looked at other people's questions regarding this type of thing and most of the reactions are "It's easier to just start a new tab bar app and transfer the content over." I still want to be able to learn how to do this though, it'll help me learn the language of X Code and Objective C better by pushing through it and make me well versed and better in the end (as it will for the others with similar questions). Thanks for putting up with my beginner questions, I'm still learning!

Drop down menu like the default iPad application menus

I'm currently working on my first iOS application to run on the iPad, and I've come across a problem. I have been asked to implement menu's similar to the ones in the default applications such as when you click on the "Calendars" button in the top left of the calendars app.
Only issue is, I cant seem to find a standard UI object that looks like these, with the arrow connecting the menu to the button etc. Is this a standard UI component that I should be able to use, or will I have to imitate them by creating a custom object?
Thanks for any help.
That is a UIPopoverController. There isn't an Interface Builder control for this. You need to create one programmatically:
UIPopoverController *popover = [[UIPopoverController alloc]initWithContentViewController:someTableViewController];
See the documentation for more information and sample projects, specifically ToolbarSearch:

Resources