From 164187c4e25fd924b1b9996520fdb62b26216db2 Mon Sep 17 00:00:00 2001 From: Marco Martin Date: Thu, 7 Jan 2010 19:22:46 +0000 Subject: [PATCH] backport the reverting of the size hint svn path=/branches/KDE/4.4/kdelibs/; revision=1071249 --- widgets/toolbutton.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/widgets/toolbutton.cpp b/widgets/toolbutton.cpp index b522eb937..e72884542 100644 --- a/widgets/toolbutton.cpp +++ b/widgets/toolbutton.cpp @@ -436,17 +436,6 @@ 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()); - int nativeMargin = nativeWidget()->style()->pixelMetric(QStyle::PM_ButtonMargin, &option, nativeWidget()); - qreal left, top, right, bottom; - d->background->getMargins(left, top, right, bottom); - hint = hint - QSize(nativeMargin, nativeMargin) + QSize(left+right, top+bottom); return hint; }