I need to detect when a CATiledLayer has finished drawing. I tried subclassing and overriding -(void)display
to set/clear a flag, but it seems that tile drawing is happening in a different thread (display just returns and then seconds later, the layer is finished drawing)
views:
458answers:
1
A:
Some things are not clear from your question. Are you asking whether all tiles have been drawn or just whether the visible tiles have finished drawing?
Assuming the later you could try drawInContext: but will likely still not give you the answer if there is scrolling. Because the tiles are cached and we have no way to know when the cached tiles are dumped you would not be able to tell if a tile has not been drawn yet or if it was just drawn from the cache.
You might want to describe what you are trying to accomplish and see if people have ideas for another way to do it.
Jon Steinmetz
2009-07-24 22:50:46
I'm trying to dynamically change levelOfDetails(Bias) setting. The problem is that sometimes, when change happens in middle of tile drawing, application hangs
esad
2009-07-24 22:58:31