patch: khtmlimage (#70334)

David Faure dfaure at klaralvdalens-datakonsult.se
Tue Jan 6 10:58:29 GMT 2004


On Monday 05 January 2004 21:56, Simon Hausmann wrote:
> Hi,
> 
> khtmlimage has some problems figuring out the image dimensions, leading to 
> bugs like #70334. What's happening is that after the requestDone signal is 
> emitted QMovie figures out it's really done and the real pixmap gets set on 
> the RenderImage, after updateWindowCaption tried to retrieve it (without 
> success, hence the 0x0 Pixels bug) . I figured the approach itself is wrong 
> and decided to change khtml to use the cache object client infrastructure 
> instead, which allows the cache to call back on us when the image really 
> arrived. The attached patch implements this. Would be cool if some kind soul 
> could give it a second test and review it :)

Is there any risk that requestImage might call notifyFinished _before_
returning (i.e. immediately)? If this happened, then the nice window caption would be
overwritten by the emit setWindowCaption( url.prettyURL() );
 in openURL.
The fix would be easy though: just move that line up, before the requestImage.

-- 
David Faure -- faure at kde.org, dfaure at klaralvdalens-datakonsult.se
Qt/KDE/KOffice developer
Klarälvdalens Datakonsult AB, Platform-independent software solutions




More information about the kfm-devel mailing list