From 4746541dcfebb73ea8398e60e046e394ea9fa441 Mon Sep 17 00:00:00 2001 From: David Edmundson <davidedmundson@kde.org> Date: Tue, 3 Dec 2013 12:25:17 +0100 Subject: [PATCH] Pass a valid style option to fetch default frame width This is useful for oxygen to return the correct size Change-Id: I0476f89f68eabf4c1a8611623095213c8f70cef2 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> --- src/controls/Private/qquickstyleitem.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controls/Private/qquickstyleitem.cpp b/src/controls/Private/qquickstyleitem.cpp index 566a46f85..4b8d71f20 100644 --- a/src/controls/Private/qquickstyleitem.cpp +++ b/src/controls/Private/qquickstyleitem.cpp @@ -1064,7 +1064,7 @@ int QQuickStyleItem::pixelMetric(const QString &metric) if (metric == "scrollbarExtent") return qApp->style()->pixelMetric(QStyle::PM_ScrollBarExtent, 0 ); else if (metric == "defaultframewidth") - return qApp->style()->pixelMetric(QStyle::PM_DefaultFrameWidth, 0); + return qApp->style()->pixelMetric(QStyle::PM_DefaultFrameWidth, m_styleoption); else if (metric == "taboverlap") return qApp->style()->pixelMetric(QStyle::PM_TabBarTabOverlap, 0 ); else if (metric == "tabbaseoverlap") -- GitLab