Initialize QStyleOptionProgressBar with QStyle::State_Horizontal
In Qt 5, QStyleOptionProgressBar::orientation was Qt::Horizontal by default. In Qt 6, we need to init state with QStyle::State_Horizontal so that code setting up a style option doesn't need to do so explicitly. Amends add8262f72befc4c6a25403a21269030111054d1 Pick-to: 6.2 Fixes: QTBUG-93412 Done-with: Volker Hilsheimer <volker.hilsheimer@qt.io> Change-Id: Iaa311cf0f4bab72c0bacbd8e698ba24660bca6b8 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
parent
04ee5795cc
commit
c0bc4c7638
@ -1535,6 +1535,7 @@ QStyleOptionProgressBar::QStyleOptionProgressBar(int version)
|
||||
minimum(0), maximum(0), progress(0), textAlignment(Qt::AlignLeft), textVisible(false),
|
||||
invertedAppearance(false), bottomToTop(false)
|
||||
{
|
||||
state |= QStyle::State_Horizontal;
|
||||
}
|
||||
|
||||
/*!
|
||||
|
Loading…
x
Reference in New Issue
Block a user