Note that there are some explanatory texts on larger screens.

plurals
  1. POUIActivityIndicatorView displayed beneath the keyboard
    primarykey
    data
    text
    <p>Inside a static library (lib.a), I have a <code>NavigationController</code> in a Storyboard that I initiate after a button tap with: </p> <pre><code>[mainWindow.rootViewController presentViewController:newController animated:NO completion:Nil]; </code></pre> <p>Within that <code>newController</code> I have a <code>UITextField</code> that I set <code>becomeFirstResponder</code> upon <code>viewDidLoad</code> and another button that when tapped I want to display a <code>UIAlertView</code> which after pressing "Ok" should show a <code>UIActivityIndicatorView</code> on top of everything (including the keyboard).</p> <p>The code am using to display the <code>UIActivityIndicatorView</code> is the following </p> <pre><code>UIWindow *mainWindow = [[UIApplication sharedApplication] keyWindow]; spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhite]; spinner.autoresizingMask = (UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleBottomMargin); spinner.center = CGPointMake(CGRectGetWidth(mainWindow.bounds)/2, CGRectGetHeight(mainWindow.bounds)/2); spinner.frame = mainWindow.bounds; spinner.backgroundColor = [UIColor darkGrayColor]; spinner.alpha = 0.7f; [mainWindow addSubview:spinner]; </code></pre> <p>and whenever the user taps on the button I execute the following: </p> <pre><code>UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"Confirmation" message:@"Are you sure?" delegate:self cancelButtonTitle:@"No" otherButtonTitles:@"Yes", nil]; [message show]; </code></pre> <p>and when tapped I have a simple method that: </p> <pre><code>//Initializing spinner [spinner startAnimating]; //Execute NSURL Connection.... </code></pre> <p>The problem is that the <code>UIActivityIndicatorView</code> does not show on top of the keyboard.</p> <p>Any ideas?</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.
    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