QTabBarPrivate::setupMovableTab() - fix initialization of tab position

The method initialized the tab position with the enum value OnlyOneTab.
=> Change this to the correct initial enum value Moving.

Fixes: QTBUG-115147
Change-Id: I4ce04f0a41dac6e93affd300eb424f4087eb7867
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 4b43a329b799f2b5d0fb2f850f03773abc6aa21b)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Axel Spoerl 2023-07-11 07:58:42 +02:00 committed by Qt Cherry-pick Bot
parent 8bad89cf53
commit 66217fe0ae

View File

@ -2243,7 +2243,7 @@ void QTabBarPrivate::setupMovableTab()
QStyleOptionTab tab;
q->initStyleOption(&tab, pressedIndex);
tab.position = QStyleOptionTab::OnlyOneTab;
tab.position = QStyleOptionTab::Moving;
if (verticalTabs(shape))
tab.rect.moveTopLeft(QPoint(0, taboverlap));
else