I have this code:
ViewController2 *childView = [[ViewController2 alloc] initWithNibName:@"ViewController2" bundle:nil];
[self.navigationController pushViewController:childView animated:YES];
I the first line, self.navigationController has a value.
On the second line, its value becomes 0. Why is that?
...
I can show a different view with this code:
[self presentModalViewController:childView animated:nil];
This code should do the same thing, right?
[self.navigationController pushViewController:childView animated:YES];
But it doesn't do anything. Why is that?
...
Why do Navigation Applications use pushViewController instead of presentModalViewController like all the other apps? How can a Navigation Application be modified to use presentModalViewController instead? Would it be sub-optimal to do so? Why?
...
In a Navigation-based application, the method pushViewController:animated can be used. This is a method of the UINavigationController class. However, nowhere in the source files do I see any #import statements that import this class. The documentation doesn't show UIViewController as inheriting from UINavigationController.
So how are Na...
Hi folks. First time posting on stack overflow.
I've spent hours scouring over many Google searches and have, at this point, practically memorized the UIView and UIViewController class reference docs. No matter what I do, my app is ignoring my efforts to resize my views on orientation change (or any other frame size modifications for th...
How do you pass an object to a view controller, right before you push the view to show it?
...
Is it possible to add a navigationController to a view application that inherits from UIViewController and not UITableViewController? How is it done?
...
Hi,
I got a MainViewController who has addes a SubViewController.
In the SubViewController there another SubSubViewController who has image inside witch will be clicked sometimes.
When touchesBegan dispatch the delegate of SubSubViewController is getting called.
Now i need this.
[mainViewController method] inside the SubSubViewContr...
Hi,
I have one Masterview.it has lot of childviews.I am using the following code to detect the touched view and to bring front the corresponding view.the code works fine.But When I add subview to childview,it did not work , any help please?
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event;
{
self.hitView = nil;
self.h...
I've been looking at the API for IOS Programming, and have been reading about view controllers and UIViews. It looks like UIViewController subclasses are really useful for Modal navigation and custom animation, but I can't see any other uses than that.
What is the benefit to using a UIViewController subclasses rather than a normal NSObj...
Hi,
Just want to know how to transition from a cocos2d scene to a UIviewcontroller view and vice-versa?
thanks,
mark
...
HI,
I have Parentview-->Multiple childviews.
when i use [self bringSubviewToFront:childview] in parentview, it works fine.but after adding grandchildview to childview,when i use
[self bringSubviewToFront: grandchildview] in parentview, it did not work?any help please?
...
Following this tutorial and this question, I attempted to create a custom UIViewController containing a UINavigationController. This mostly worked, except that the controller takes up the full screen and so the status bar overlaps it. Downloading the tutorial's source and running it, I found that the tutorial had the same problem (it use...
The Apple documentation gives the following warning regarding using View Controllers to manage part of a screen.
Note: You should not use view
controllers to manage views that fill
only a part of their window—that is,
only part of the area defined by the
application content rectangle. If you
want to have an interface compos...
Hello All,
I am developing an application. I'm getting a very strange problem. In iPhone 3GS,4.0 the app works fine but in iPhone 3g there is a straight red line appears in some View Controllers automatically. Also the static background image got weird. Does anyone faces this kind of problem. Any help will be appreciated.
Thanks
...
What I'm trying to build is an application that allows users to add a category to the first entity (CategoryItem) and then add feeds to that via a second entity (FeedItem).
So far, the CategoryItem entity has *action attribute which is used as the naming of the category (String). The FeedItem entity has two attributes, *feedName and *f...
I want to use a modal view (UIViewController) as a "normal" view, which can be pushed on the navigation controller stack. Normally, a modal view is presented like this:
LoginViewController *myView = [[MyViewController alloc] init];
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:myView]...
My question is about the best way to implement passing of information between UIViewControllers.
If I have an application with 2 ViewControllers and for example a user selects an item in ViewControllerA which should then show the item and more details in ViewControllerB.
What would be the best way to implement this? via the appdelegat...
Hey all,
I'm trying to present a view over another. Essentially, the view I want to present has some information in the middle and the rest of the space is transparent. I want this view to pop-up, while leaving the current view in the background behind the transparency.
Whenever I try to pushViewController or presentModalViewController...
I am using the iPhone toolchain on Linux and so I have no Interface Builder. So how could I layout my view in my ViewController subclass? For example, I want a UITextView in the middle of the screen? Should I do this in the loadView or viewDidLoad. Do I also have to set the view for the ViewController subclass to itself?
...