Re: Waiting for UIWebView with Dispatch Semaphores

2010-12-21 Thread Jeff Kelley
On Tue, Dec 21, 2010 at 11:59 AM, David Duncan wrote: > > Why do this synchronously at all? The web view already gives you a > notification, use that to generate your thumbnail and signal the caller. What I’m trying to do is create a thumbnail for a PowerPoint that, when clicked, opens a web vie

Re: Waiting for UIWebView with Dispatch Semaphores

2010-12-21 Thread David Duncan
On Dec 21, 2010, at 8:52 AM, Jeff Kelley wrote: > Is there a way to synchronously wait for the web view? All > combinations of splitting things off on separate threads fall apart > when I try to wait for the image to be created. Why do this synchronously at all? The web view already gives you a

Waiting for UIWebView with Dispatch Semaphores

2010-12-21 Thread Jeff Kelley
I’m trying to create a synchronous method on iOS (4.2.1) to create a thumbnail image for a PowerPoint file. To accomplish this, I want to load the file into a web view, then wait for it to load, then render its context into a new graphics context and save it to an image. Here’s what I have so far: