Fixed wrong size calculation in CAutoHideDockContainer updateSize() function

This commit is contained in:
Uwe Kindler 2022-11-02 07:29:45 +01:00
parent 540961b8dd
commit 983afc4d1e

View File

@ -228,7 +228,7 @@ void CAutoHideDockContainer::updateSize()
switch (sideBarLocation()) switch (sideBarLocation())
{ {
case SideBarLocation::Top: case SideBarLocation::Top:
resize(rect.width(), qMin(rect.height(), d->Size.height() - ResizeMargin)); resize(rect.width(), qMin(rect.height() - ResizeMargin, d->Size.height()));
move(rect.topLeft()); move(rect.topLeft());
break; break;
@ -248,7 +248,7 @@ void CAutoHideDockContainer::updateSize()
case SideBarLocation::Bottom: case SideBarLocation::Bottom:
{ {
resize(rect.width(), qMin(rect.height(), d->Size.height() - ResizeMargin)); resize(rect.width(), qMin(rect.height() - ResizeMargin, d->Size.height()));
QPoint p = rect.bottomLeft(); QPoint p = rect.bottomLeft();
p.ry() -= (height() - 1); p.ry() -= (height() - 1);
move(p); move(p);