[webkit-dev] Async IconDatabase and reading icons from disk on startup

Adam Treat treat at kde.org
Sun May 11 19:20:06 PDT 2008


On Sunday 11 May 2008, Darin Adler wrote:
> Or you could do as Safari does and call iconForPageURL twice; the
> first time it's "display the icon if we already have it" but the
> second time it's "I heard you have a new icon, lets display the new
> icon we now know about".
>
> It would probably be cleaner if triggering the load of the icon was
> completely separate from actually fetching the icon data.

Right.  I would suggest that iconForPageURL should always return 0 unless and 
until readIconForPageURLFromDisk is called which actually triggers the load. 

It should be noted that *nothing* currently uses 
readIconForPageURLFromDisk() ;)

I guess I just couldn't believe that Safari calls iconForPageURL twice.  It is 
very unclear API.

Adam


More information about the webkit-dev mailing list