take in consideration the size hint of the internal widget for the own

sized hint

svn path=/trunk/KDE/kdelibs/; revision=1038245
This commit is contained in:
Marco Martin 2009-10-20 21:37:46 +00:00
parent 2e18ea7af8
commit 82317bda2d

View File

@ -480,7 +480,7 @@ QSizeF ScrollWidget::sizeHint(Qt::SizeHint which, const QSizeF & constraint) con
QSizeF hint = QGraphicsWidget::sizeHint(which, constraint);
if (which == Qt::PreferredSize && d->widget) {
return d->widget->size();
return d->widget->size().expandedTo(d->widget->effectiveSizeHint(Qt::PreferredSize));
}
return hint;