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

Darin Adler darin at apple.com
Sun May 11 19:02:52 PDT 2008


On May 11, 2008, at 6:44 PM, Adam Treat wrote:

> How is it actually read from disk then?  Looking at the code... the  
> only time it is actually read from disk is in  
> IconDatabase::readFromDatabase and even then it only reads in icons  
> that are flagged in m_iconsPendingReading.  And when grepping the  
> code the only time I see that an icon is inserted into  
> m_iconsPendingReading is when iconForPageURL is called?

I guess my knowledge of the class is out of date and incomplete.

Studying further, I think that clients also need to call  
readIconForPageURLFromDisk as well as retainIconForPageURL.

And as you say, this does mean that iconForPageURL is called twice,  
but strictly speaking that's an implementation detail.

     -- Darin



More information about the webkit-dev mailing list