]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/settings/trash/trashsettingspage.cpp
[PlacesItemModelTest] Check whether Desktop and Download folders exist
[dolphin.git] / src / settings / trash / trashsettingspage.cpp
index 237a1798788c365e1d9babdf5afa456207934acc..a9b8c734c7a0516571ee1987e05b40438ca2b30a 100644 (file)
 
 #include <KCModuleProxy>
 
-#include <QVBoxLayout>
+#include <QFormLayout>
 
 TrashSettingsPage::TrashSettingsPage(QWidget* parent) :
         SettingsPageBase(parent)
 {
-    QVBoxLayout* topLayout = new QVBoxLayout(this);
-    QWidget* vBox = new QWidget(this);
-    QVBoxLayout *vBoxVBoxLayout = new QVBoxLayout(vBox);
-    vBoxVBoxLayout->setMargin(0);
+    QFormLayout* topLayout = new QFormLayout(this);
 
-    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.
-    QWidget *w = new QWidget(vBox);
-    vBoxVBoxLayout->addWidget(w);
-    
-    topLayout->addWidget(vBox);
+    m_proxy = new KCModuleProxy(QStringLiteral("kcmtrash"));
+    topLayout->addRow(m_proxy);
 
     loadSettings();