]> cloud.milkyroute.net Git - dolphin.git/commitdiff
[InformationPanel] Remove obsolete intermediate wrapper widget/layout
authorStefan Brüns <stefan.bruens@rwth-aachen.de>
Mon, 22 Apr 2019 11:42:34 +0000 (13:42 +0200)
committerStefan Brüns <stefan.bruens@rwth-aachen.de>
Mon, 22 Apr 2019 11:43:31 +0000 (13:43 +0200)
The Baloo::MetaDataWidget is now able to stretch in a meaningful way
by itself, remove the wrapper.

Summary: Depends on D20667

Reviewers: #dolphin, #baloo, #frameworks, ngraham, astippich, elvisangelaccio

Reviewed By: #dolphin, #baloo, ngraham, elvisangelaccio

Subscribers: kfm-devel

Tags: #dolphin

Differential Revision: https://phabricator.kde.org/D20668

src/panels/information/informationpanelcontent.cpp

index fe77e2bb8448d14e98fdc99882c1283c49cbbe8d..6e718f961dc74f0e7f366f06e1b26d0e0128f920 100644 (file)
@@ -107,18 +107,8 @@ InformationPanelContent::InformationPanelContent(QWidget* parent) :
     m_metaDataWidget->setFont(QFontDatabase::systemFont(QFontDatabase::SmallestReadableFont));
     m_metaDataWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Minimum);
 
-    // Encapsulate the MetaDataWidget inside a container that has a dummy widget
-    // at the bottom. This prevents that the meta data widget gets vertically stretched
-    // in the case where the height of m_metaDataArea > m_metaDataWidget.
-    QWidget* metaDataWidgetContainer = new QWidget(parent);
-    QVBoxLayout* containerLayout = new QVBoxLayout(metaDataWidgetContainer);
-    containerLayout->setContentsMargins(0, 0, 0, 0);
-    containerLayout->setSpacing(0);
-    containerLayout->addWidget(m_metaDataWidget);
-    containerLayout->addStretch();
-
     m_metaDataArea = new QScrollArea(parent);
-    m_metaDataArea->setWidget(metaDataWidgetContainer);
+    m_metaDataArea->setWidget(m_metaDataWidget);
     m_metaDataArea->setWidgetResizable(true);
     m_metaDataArea->setFrameShape(QFrame::NoFrame);