[PATCH] kdirlister (Re: How can we improve perceived response time?)

Waldo Bastian bastian at kde.org
Sun Nov 24 20:05:41 GMT 2002


On Sunday 24 November 2002 17:29, Maks Orlovich wrote:
> > Which delays the mimetype detection till somewhat later for all files,
> > and that made things actually slower. No idea why.
>
> Would that cause an additional repaint?

Seems like it... calls to QIconView::drawContents() increase from 5 to 12 due 
to this.

I suddenly have 8 of those calls between
kio (KDirListerCache): [void KDirListerCache::slotEntries(KIO::Job*, const 
KIO::UDSEntryList&)] new entries for file:/home/bastian

and

kio (KDirListerCache): [void KDirListerCache::slotResult(KIO::Job*)] finished 
listing file:/home/bastian

without the patch I only have 2 of such calls.

There is also an extra QIconView::drawContents() just before 
konqueror: KonqKfmIconView::slotRenderingFinished()

These calls seem to be coming from KMimeTypeResolver, who does delayed 
mimetype detection. That makes sense as konq_iconview.cc:759 says:
        if ( !(*it)->isMimeTypeKnown() )
            m_mimeTypeResolver->m_lstPendingMimeIconItems.append( item );

Appearantly delayed mimetype detection is rather slow due to all the updates 
it causes but due to some lucky side-effect of mimetype-filtering it never 
gets triggered.

Cheers,
Waldo





More information about the kfm-devel mailing list