[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdelibs/khtml/misc
From: Germain Garand <germain () ebooksfrance ! com>
Date: 2004-10-11 2:00:59
Message-ID: 20041011020059.965DB16BD1 () office ! kde ! org
[Download RAW message or body]
CVS commit by ggarand:
alternate fix for 'invalid pixmap parameter'.
better make sure the returned pixmap is resized to null when the rect is invalid.
M +7 -4 loader.cpp 1.175
--- kdelibs/khtml/misc/loader.cpp #1.174:1.175
@@ -587,13 +587,16 @@ const QPixmap &CachedImage::pixmap( ) co
if(m)
{
- if(m->framePixmap().size() != m->getValidRect().size() && m->getValidRect().isValid())
+ if(m->framePixmap().size() != m->getValidRect().size())
{
// pixmap is not yet completely loaded, so we
// return a clipped version. asserting here
// that the valid rect is always from 0/0 to fullwidth/ someheight
- if(!pixPart) pixPart = new QPixmap(m->getValidRect().size());
+ if(!pixPart) pixPart = new QPixmap();
(*pixPart) = m->framePixmap();
+ if (m->getValidRect().size().isValid())
pixPart->resize(m->getValidRect().size());
+ else
+ pixPart->resize(0, 0);
return *pixPart;
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic