Note that there are some explanatory texts on larger screens.

plurals
  1. POUITableView loading images after app loads
    primarykey
    data
    text
    <p>so I'm writing an app, and it fetches album artwork from website URLs.</p> <p>Basically how I have it written thus far is that a file is read in, which contains URLs to the album artwork. Then a two dimensional NSMutableArray is constructed with data from the file, and UIImages initialized from the individual URLs from the file, and then stored in the array.</p> <p>The array is then loaded into the UITableView.</p> <p>This works great... except it takes like, 10 seconds to load the app (lol).</p> <p>So is there any way to load the images once the UITableView is loaded?</p> <p>Here's my cellForRowAtIndexPath method if it helps.</p> <pre><code>- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"identifier"]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"identifier"]autorelease]; } ((UILabel *)[cell viewWithTag:artistTag]).text = [[musicList.list objectAtIndex:indexPath.row] objectAtIndex:artistIndex]; ((UILabel *)[cell viewWithTag:albumTag]).text = [[musicList.list objectAtIndex:indexPath.row] objectAtIndex:albumIndex]; ((UILabel *)[cell viewWithTag:dateTag]).text = [[musicList.list objectAtIndex:indexPath.row] objectAtIndex:dateIndex]; ((UIImageView *)[cell viewWithTag:imageTag]).image = [[musicList.list objectAtIndex:indexPath.row] objectAtIndex:imageIndex]; return cell; </code></pre> <p>}</p> <p>Thanks a lot!</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