dismiss

How can i present self as a modal view controller?

Hello, I am developing a game using OpenGL. I need to load some images from the web when the game starts (only if there are new ones available). And to do this I decided to create a view controller exactly like Default.png and do the loading there using a UIProgressView. I then added it as subview of my window. Load the images and onc...

MPMoviePlayer dismiss when pressed

Hi. I have a MPMoviePlayer setup to play an intro movie to my application. That works just great, the only problem is that it lasts for 14 seconds, and I want to give my users a chance to skip the intro by pressing anywhere on the movie. I have hidden the movie controls, as they are not needed. Code: NSString *introPath = [[NSBundle ...

Iphone View origin changes after presentModal

Hi, In my application i present a UIImagePicker. When i dismiss this modal, my rootView goes from origin.x=5 to origin.x=0. Does somebody knows why my view will automatically changes the origin when i dismiss or present my modalViewController? I tried resetting the origin in viewDidAppear and viewWillAppear, but no luck. If i change t...

How do I detect when a UIActionSheet has been dismissed?

I'm pretty new to iPhone dev, so any help is appreciated. I am creating an action sheet within a function and adding it to the current view. I have the sheet delegate as 'self' and the action sheet is not retained. Is there a function like the datePicker's didSelectRow? Something like "didDismissWithButtonAtIndex" or something that lets...

Adding BarButtons to a UINavigationBar after presenting a modal view controller.

I'm using the template for a "Utility Application". In the "FlipSideViewController", I added an IBOutlet for a UINavigationController, navController. In the code, I added the navController just fine. The rootViewController loads perfectly: navController.viewControllers = [[NSArray arrayWithObject:rootViewController] retain]; [self.vi...

Dismissing iPad UIPopoverController when BarButtonItem is pushed while it's open

Using a split view on the iPad, I have the following code: - (void)splitViewController: (UISplitViewController*)svc willHideViewController:(UIViewController *)aViewController withBarButtonItem:(UIBarButtonItem*)barButtonItem forPopoverController:(UIPopoverController*)pc { barButtonItem.title = @"Categories"; NSMutableArray *items = [[t...

Correct way of showing consecutive modalViews

I have two views that need to be shown modally, one after the other. This doesn't work if we dismiss and show consecutively, like this: [rootController dismissModalViewControllerAnimated: YES]; [rootController presentModalViewController: psvc animated: YES]; The second modal view simply doesn't show up. I've seen a fix that was somet...

UIAlertView Dismiss Not Really Dismissed

Below is the code I'm using to do a retry on an FBConnect session. When the [self loginToFaceBook] fires FBConnect adds a subview to 'window' which is still the UIAlert view, so when the UIAlert really dismisses it takes the FBConnect view with it. Any idea as to the best way to wait for the UIAlert view to be gone. -(void)alertView:(...

iPhone - Dismiss modal view by a UITabBarController

Hi everyone, I've got into a very strange problem. I created my own UITabBarController to customize it and it works pretty well... except for the modal views. When I dismiss the modal view (present/dismiss from the UITabBarController) with an animation, it waits until the animation did finished and goes to the first controller of the ta...

iPhone - dismiss multiple ViewControllers

Hi there, I have a long View Controllers hierarchy; in the first View Controller I use this code: SecondViewController *svc = [[SecondViewController alloc] initWithNibName:@"SecondViewController" bundle:nil]; [self presentModalViewController:svc animated:YES]; [svc release]; In the second View Controller I use this code: Third...

dismiss UIPopoverController (if visible) after tapping a UIBarButtonItem

I'm trying to dismiss any currently visible UIPopoverControllers if/when another UIBarButtonItem is tapped as seen on Pages for the iPad when tapping between Styles/Media/Tools etc. I've done this, but it's too specific. Looking for something generic. if ([popoverController isPopoverVisisble]) { [popoverController dismissPopoverAnimat...

after dismissing modal view, parent view seems deallocated??

I'm writing an iPhone app. Starting from a view controller in a navigation stack [called EditCreatorController], I am presenting a custom modal view controller [called BMSStringPickerController]. I have created a delegate protocol, etc. per the Apple guidelines for passing data back to the first view and using that view to dismiss the mo...

Dismissing multiple modal view controllers at once?

So have a stack with three view controllers where A is root, B is first modal view controller and C is third modal vc. I would like to go from C to A at once. I have tried this solution to dismiss.It does work but not in a correct way. That is when the last view controller is dismissed it will breifly show the second view controller befo...

How do i make my progress dialog dismiss after webview is loaded?

What do I need to my code to make the dialog dismiss() after the webview is loaded? public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); CookieSyncManager.createInstance(this); CookieSyncManager.getInstance().startSync(); ...

ResignFirstResponder doesn't dismiss the keyboard (iPhone)

Hi all, I've searched through this site that I couldn't find a solution to the problem I'm facing now. Hope someone can help. I've created a UIAlertView to prompt user to enter their name in an iPhone app. UIAlertView *enterNameAlert = [[UIAlertView alloc] initWithTitle:@"Enter your name" ...

Reload Data On View Controller Dismiss

I have a table view, which populates data from the web. To add information to this list I have a configuration screen presented modally. When data is added successfully the configuration screen is dismissed, I would like the data in the table view to automatically reload from the web to reflect the newly added data. What is the best w...

dismiss UIActionSheet when App goes in background on iOS4

In the app I am working on, I have action sheets and alert views which I would like dismissed when app enters the inactive/ background state. I am using the UIApplicationWillResignActiveNotification instead of the UIApplicationDidEnterBackgroundNotification as I want the code to be compatible with iOS3.2. -(void)applicationWillResign...

Dismissing iPad modal view messes up the UISplitView panels

The premise is remarkably simple: I want to display a modal view in an iPad app that uses a UISplitViewController. The view hierarchy is straight-forward: /- TableViewController1 /- root:TabBarController -- TableViewController2 SplitViewController - ...

ProgressDialog dismiss() function does not work !

It works great on emulator but when i try it on Samsung Galaxy S, ProgressDialog keeps showing untill to force close the application. @Override public void onCreate(Bundle savedInstanceState) { . . . pd = ProgressDialog.show(this, "Working..", "Searching for words !",...

Dismissing the keyboard using firstResponder

To dismiss the keyboard I use either one of the following: [sender dismissFirstResponder] [self dismissFirstResponder] The problem is, I have a situation where the user selects a text field, and some other text field is the first responder with the keyboard showing. I want to dismiss the keyboard when this particular text field is sel...