X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/01e4f60a0931aba506b184d384a4e2f926b2233c..d1a70c0b629b:/src/settings/trash/trashsettingspage.cpp diff --git a/src/settings/trash/trashsettingspage.cpp b/src/settings/trash/trashsettingspage.cpp index bd01d56b5..dd6038fb6 100644 --- a/src/settings/trash/trashsettingspage.cpp +++ b/src/settings/trash/trashsettingspage.cpp @@ -20,32 +20,20 @@ #include "trashsettingspage.h" #include -#include -#include -#include +#include TrashSettingsPage::TrashSettingsPage(QWidget* parent) : SettingsPageBase(parent) { - const int spacing = KDialog::spacingHint(); + QFormLayout* topLayout = new QFormLayout(this); - QVBoxLayout* topLayout = new QVBoxLayout(this); - KVBox* vBox = new KVBox(this); - vBox->setSpacing(spacing); - - m_proxy = new KCModuleProxy("kcmtrash"); - topLayout->addWidget(m_proxy); - - // Add a dummy widget with no restriction regarding - // a vertical resizing. This assures that the dialog layout - // is not stretched vertically. - new QWidget(vBox); - topLayout->addWidget(vBox); + m_proxy = new KCModuleProxy(QStringLiteral("kcmtrash")); + topLayout->addRow(m_proxy); loadSettings(); - connect(m_proxy, static_cast(&KCModuleProxy::changed), this, &TrashSettingsPage::changed); + connect(m_proxy, QOverload::of(&KCModuleProxy::changed), this, &TrashSettingsPage::changed); } TrashSettingsPage::~TrashSettingsPage()