]> cloud.milkyroute.net Git - dolphin.git/commitdiff
[PhononWidget] Fix layout warning
authorElvis Angelaccio <elvis.angelaccio@kde.org>
Sun, 24 Mar 2019 10:55:12 +0000 (11:55 +0100)
committerElvis Angelaccio <elvis.angelaccio@kde.org>
Sun, 24 Mar 2019 10:55:12 +0000 (11:55 +0100)
`controlsLayout` should not be a direct child of the widget, since it
already has `m_topLayout` as layout.

This fixes the following warning:

    QLayout: Attempting to add QLayout "" to PhononWidget "", which already has a layout

src/panels/information/phononwidget.cpp

index 95f535713c32b0f8d24b157ea1374f0b1d67ae53..77e066d372559e2e03a59285eb272f7eb2d34e08 100644 (file)
@@ -106,7 +106,7 @@ void PhononWidget::showEvent(QShowEvent *event)
         m_topLayout = new QVBoxLayout(this);
         m_topLayout->setContentsMargins(0, 0, 0, 0);
 
-        QHBoxLayout *controlsLayout = new QHBoxLayout(this);
+        QHBoxLayout *controlsLayout = new QHBoxLayout();
         controlsLayout->setContentsMargins(0, 0, 0, 0);
         controlsLayout->setSpacing(0);