Set up view controllers like Find My Friends iPad app - uiviewcontroller

I want to set up my view controllers like the Find My Friends iPad app. Based on what I've found so far, I believe that I need to:
Use a container view controller
Make the tab bar controller the root view controller of the container view controller
Add other view controllers, such as split view controller, as child view controllers to tab bar controller
Add some sort of callback methods to forward messages from the parent to the child view controllers (for rotation and appearance)
Can someone please confirm that I am on the right track? Also, if you can point to or add some sample code to help me get started, I will appreciate it.
Thank you.

You are correct. All 4 tabs on the "Find my Friends" iPad app are split views. It is actually very simple to get started with an app like that. I'm not sure what direction you are planning to take as far as content, but at least for the layout. Start a new project in Xcode and then choose master-detail application. It will automatically setup a split view with the left side as a table view and the rightside as a detail view. it will also presetup some editing methods and what nots. If you will be using core data at all, i would also highly suggest starting that with the checkmark as well. Good luck with your app!

Related

Redirecting To a New Angular Application After Login and Subscription Success

Good Day Everyone, Please I am working on a personal project on Angular, I have two angular applications, the main angular application and the second angular application to redirect to after login and subscription has been validated.
The Only issue now is how to make use of the home.component.html of the second application which contains different menu or navbar items but each time i redirect to the second application, the items or menu showing on the navbar are the main or default application component.html but with the second angular application contents. I also discovered that second application was not generated with any index.html file.
Please I need help on how to go about this. In summary two angular applications one acting as default (thriller page), the second to display the real contents for movies. How can i implement the default application having its own menu and the second application having its own menu as well. Thanks
Use window.location.href = 'SecondAppUrl'; to navigate to the second app.

lockscreen on web page

I want to create fancy lock screen on my web portal. For javascript and timer I used https://github.com/maxfierke/jquery-sessionTimeout-bootstrap plugin. I got idea from many bootstrap admin templates like: http://webapplayers.com/inspinia_admin-v1.2/lockscreen.html.
If I use only javascript, page will be displayed (redirected), but, I can easy back on previous page. Maybe I need expand my DB table with new column for detecting lock screen or enough create a cookie with some parameters.
Any idea, what is the best way to solve it?

Child content view controller view has wrong bounds size from Storyboard?

This document outline from my sample Storyboard shows what I'm working with.
I have a custom container view controller and two content view controllers connected via embed segues.
Here is the storyboard itself.
ZetaViewController has to create some programmatic views (within ZetaView, of course). I noticed when I was centering these programmatically created views they seemed really off center.
ZetViewController is centering things by examining self.view.bounds.size.height and self.view.bounds.size.width and doing some appropriate arithmetic.
When I added debug logging to ZetaViewController, I noticed that self.view.bounds.size.height and self.view.bounds.size.width had dimensions equal to ContainerView (768 x 1004) and not ZetaView (728 x 637). The Size Inspector in IB confirms these values.
I created a distinctive value for the tag attribute of ZetaView and logged it. ZetaViewController.view really is ZetaView because the tag value confirms it.
So what is going on? Why would ZetaView, shown clearly with smaller dimensions on the Storyboard and in the Size Inspector, show the wrong values in it's properties during run time?
My problem had nothing to do with Storyboards, segues, or custom container view controllers vs content view controllers. It had to do with the new Cocoa Auto Layout features introduced in iOS 5.
My problem arose from inspecting view bounds size in viewDidLoad instead of in viewWillLayoutSubviews. At the time viewDidLoad is called, the view controller's view has not been given its proper size yet. When I moved the code which programmatically centers views to viewWillLayoutSubviews, it worked as I expected. I still leave view creation code in viewDidLoad because viewWillLayoutSubviews is called repeatedly as layout changes.
See also the View Programming Guide for iOS section "Tweaking the Layout of Your Views Manually".
Ok,I'm going to point to an excellent post that I found: (updated)
http://kevindew.me/post/18579273258/where-to-progmatically-lay-out-views-in-ios-5-and
I was having an awful time adding shadow calayers to views after autolayout had done its magic. viewDidLoad, viewWillLoad etc did not have everything correctly laid out.
viewWillLayoutSubviews is called quite a few times and the state isn't fully set up. However... In viewDidLayoutSubviews, finally everything was set up as I expected.

MonoTouch - IOS5 Storyboard - Additional View Controllers

I am new to Monotouch and I am not finding the right documentation to do this.
I created a new iPad Storyboard Single View application. I have my inital Navigation Controller, my initial View Controller, and then I added two more View Controllers (Pages?). I created a button on the first two pages. I held down control and dragged each button to the next View Controller and setup each Segue as a push. When I run my application, I can move from page 1 to page 3 and back, no problems.
Now the problem is when I start adding controls and trying to wire them up. On the initial View Controller, I can hold down Control and drag controls over to the code and after I give it a name, it automatically adds my outlets and actions.
But the new two View Controllers I cannot do this. I have searched every where and the StoryBoard documentation and examples are difficult to find. Any help would be appreciated. Thanks!
You need to create a UIViewController class for each of the new View Controllers in Xcode, if you right click on the folder for where you want to create the class, then click Add New.
You then need to then wire them up to your View Controllers in the storyboard (you will see a drop down which shows the name of the class for the view controller in the properties I think it's the fourth icon from the right, it will be UIViewController). Once you have done this, you will then be able to wire up the controls on it.
Once you've saved it, it will automatically create the C# classes in MonoDevelop when you switch back to MonoDevelop. Don't try and do the class in Mono first as it causes you all sorts of issues!
Hope that helps, if you want more information about storyboards, I've found that the objective c stuff is about as good as you can get for now as there isn't too much support for monotouch storyboarcs yet.
Davoc

using PopUpManager in a Flex 4.5 Mobile App

This is more of a best practices question rater than something technical.
I'm working on a mobile app using the Flex 4.5 SDK and I'm trying to figure out the best way to handle notification windows. In most cases these windows will be alerting the user to when something goes wrong. Ex: bad login, no data, cannot resolve server.
I'm using a singleton design pattern, I have a Requests class that handles server calls. Most popups will be originating from this class (IOErrorEvents from my loader being used to access the API). Since this class is a singleton and is used from all Views inside the app it is not aware of applications current view. I'm also not sure having this class keep track of the current view and having it push popups on top of it would be best practice.
I'm hoping that I can use PopUpManager to keep track of where to add popups and what popups are currently on the stage. Though all examples I've seen online about this show static Components being used in a views Declarations tag.
I'm really just looking for any examples or input on how you would solve this problem. Any help would be greatly appreciated!
I had the same problem, and sorted it by making an Alert popup component that you can call from anywhere in the code base, and it will pop up in the currently active window. It also has an always visible scrollbar text area which is handy
http://bbishop.org/blog/?p=502
It works for a view navigator application, but if your using a tabbed navigator application, you can add a call for that, or simply change the code to
mainTabbedNavigator = FlexGlobals.topLevelApplication.tabbedNavigator;
currentTab = mainTabbedNavigator.selectedNavigator as ViewNavigator;