From f28b0fe6a10b105ce9323195185b558a14f54e65 Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 23 Mar 2021 09:08:45 +0100 Subject: [PATCH] QtSupport: Use createSubWidget for Qml related aspects Change-Id: I8ceb64cdd96abe241fd81b411200871e7d061a97 Reviewed-by: David Schulz --- src/plugins/qtsupport/qtbuildaspects.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/qtsupport/qtbuildaspects.cpp b/src/plugins/qtsupport/qtbuildaspects.cpp index 00dd4633dc1..e2000048fed 100644 --- a/src/plugins/qtsupport/qtbuildaspects.cpp +++ b/src/plugins/qtsupport/qtbuildaspects.cpp @@ -52,7 +52,7 @@ QmlDebuggingAspect::QmlDebuggingAspect() void QmlDebuggingAspect::addToLayout(LayoutBuilder &builder) { SelectionAspect::addToLayout(builder); - const auto warningLabel = new Utils::InfoLabel({}, Utils::InfoLabel::Warning); + const auto warningLabel = createSubWidget(QString(), InfoLabel::Warning); warningLabel->setElideMode(Qt::ElideNone); builder.addRow({{}, warningLabel}); const auto changeHandler = [this, warningLabel] { @@ -85,7 +85,7 @@ QtQuickCompilerAspect::QtQuickCompilerAspect() void QtQuickCompilerAspect::addToLayout(LayoutBuilder &builder) { SelectionAspect::addToLayout(builder); - const auto warningLabel = new Utils::InfoLabel({}, Utils::InfoLabel::Warning); + const auto warningLabel = createSubWidget(QString(), InfoLabel::Warning); warningLabel->setElideMode(Qt::ElideNone); warningLabel->setVisible(false); builder.addRow({{}, warningLabel});