Thursday 15 April 2010

iphone - Delayed UIImageView Rendering in UITableView -


After

OK, I've found a UITableView custom UITableViewCell Together they have a UIImageView whose picture is being downloaded asynchronous by a NSURLConnection . All the beautiful standard stuff ...

The issue is, when the table scrolls, new images are downloaded in the background correctly but not rendered until the table stops moving.

How do I even take table to present my content when it is growing? . Thank you

- Update -

After looking closely, I'm finding that NSURLConnection representative methods are closed until the table stops being active . not sure why. Any help would be great.

"itemprop =" text ">

cause connection delegate messages are active until you have to stop scrolling because during scrolling, run loop is in UITrackingRunLoopMode . By default, the program in NSURLConnection is the only NSDefaultRunLoopMode , while you do not get any message while scrolling.

How to set connection time here in "normal" mode, in which UITrackingRunLoopMode :

  NSURLRequest * request = ... NSURLConnection * Connection = [[NSURL allocated connection] initWithRequest: Request Rep: Auto Start Import: No]; [Connection Schedule Infinite Roll: [NSRunLoop currentRunLoop] forMode: NSRunLoopCommonModes]; [Connection start];  

Note that you have to specify startImmediately that: not is the operator, which shows the documentation of Apple that you also run it after the loop mode It seems to have started to run counter to start.


No comments:

Post a Comment