take the max between width and height

svn path=/trunk/KDE/kdelibs/; revision=1118354
This commit is contained in:
Marco Martin 2010-04-24 14:03:48 +00:00
parent 35cb858197
commit 6bad7500be

View File

@ -671,7 +671,7 @@ QSizeF IconWidget::sizeHint(Qt::SizeHint which, const QSizeF & constraint) const
if (d->iconSvgElement.isNull()) {
iconSize = qMax(d->iconSvg->size().width(), d->iconSvg->size().height());
} else {
iconSize = qMax(d->iconSvg->elementSize(d->iconSvgElement).width(), d->iconSvg->elementSize(d->iconSvgElement).width());
iconSize = qMax(d->iconSvg->elementSize(d->iconSvgElement).width(), d->iconSvg->elementSize(d->iconSvgElement).height());
}
d->iconSvg->resize(oldSize);
}