resize at the hint when the orientation is set. useful when it's not in

a layout
BUG:203908

svn path=/trunk/KDE/kdelibs/; revision=1012110
This commit is contained in:
Marco Martin 2009-08-16 20:15:25 +00:00
parent fb79ff6b93
commit bd352af269

View File

@ -108,12 +108,14 @@ QString ScrollBar::styleSheet()
QScrollBar *ScrollBar::nativeWidget() const
{
return static_cast<QScrollBar*>(widget());
return static_cast<QScrollBar *>(widget());
}
void ScrollBar::setOrientation(Qt::Orientation orientation)
{
static_cast<QScrollBar*>(widget())->setOrientation(orientation);
QScrollBar *native = static_cast<QScrollBar *>(widget());
native->setOrientation(orientation);
resize(native->sizeHint());
}
}