don't change margins if the hint is empty

svn path=/trunk/KDE/kdelibs/; revision=1071059
This commit is contained in:
Marco Martin 2010-01-07 12:53:54 +00:00
parent a1d1b12624
commit 81e9c74cd3

View File

@ -436,6 +436,10 @@ QSizeF ToolButton::sizeHint(Qt::SizeHint which, const QSizeF & constraint) const
{
QSizeF hint = QGraphicsProxyWidget::sizeHint(which, constraint);
if (hint.isEmpty()) {
return hint;
}
//replace the native margin with the Svg one
QStyleOption option;
option.initFrom(nativeWidget());