Note that there are some explanatory texts on larger screens.

plurals
  1. POSwitching cells in UITableView after one has been chosen and performSegueWithIdentifier:sender: has been called
    primarykey
    data
    text
    <p>I am having trouble with a UITableView and segueing from it. The table view contains a list of places, and when a cell is clicked it segues to a list of photos from that place. It takes a bit of time to load the info for those photos, so it sticks on the list of places for a bit. My problem is that I don't want to freeze the user out of the app while it's loading, and if the user decides to switch the place they want, I want them to be able to. Is there a simple solution for this, or would it require a redesign? Here's what's called when the cell is clicked:</p> <pre><code>- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { self.activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleGray]; [self.activityIndicator startAnimating]; [[tableView cellForRowAtIndexPath:indexPath] setAccessoryView:self.activityIndicator]; self.query = ^{return [FlickrFetcher photosInPlace:self.locationDataArray[indexPath.row] maxResults:50];}; self.locationSelected = [[self.locationDataArray[indexPath.row] valueForKeyPath:@"_content"] componentsSeparatedByString:@","][0]; [self performSelector:@selector(pushView:) withObject:tableView afterDelay:0.0]; // Allows spinner to start spinning before the segue is actually performed. } - (void)pushView:(UITableView *)tableView { [self performSegueWithIdentifier:@"Display Image List" sender:self]; } </code></pre> <p>I've tried dispatching <code>performSegueWithIdentifire:sender:</code> to the main queue, but no luck (I didn't think it would work, anyway). Query is what's executed by the destination view controller. Any ideas on how to get it to work?</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.
    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