uic: write out min/maximumSectionSize property before current size

Since faff43348b the min/maxSectionSize is
respected when setting the current/default section size programatically.
This is not honored when writing out the properties and therefore the
default section size is not correctly set when it's smaller then the
default minimum section size.
Therefore make sure to set min/maxSectionSize property before all other
properties.

Fixes: QTBUG-74352
Change-Id: I8f9ede3e90b7c9c65f8440953b00e1d9d6006d38
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This commit is contained in:
Christian Ehrlicher 2019-03-12 20:43:35 +01:00
parent a6154ca648
commit 02c25f334d

View File

@ -767,9 +767,9 @@ void WriteInitialization::acceptWidget(DomWidget *node)
static const QLatin1String realPropertyNames[] = { static const QLatin1String realPropertyNames[] = {
QLatin1String("visible"), QLatin1String("visible"),
QLatin1String("cascadingSectionResizes"), QLatin1String("cascadingSectionResizes"),
QLatin1String("minimumSectionSize"), // before defaultSectionSize
QLatin1String("defaultSectionSize"), QLatin1String("defaultSectionSize"),
QLatin1String("highlightSections"), QLatin1String("highlightSections"),
QLatin1String("minimumSectionSize"),
QLatin1String("showSortIndicator"), QLatin1String("showSortIndicator"),
QLatin1String("stretchLastSection"), QLatin1String("stretchLastSection"),
}; };