Commit 4e117335 authored by Laurent Montel's avatar Laurent Montel 😁

Fix layout

parent ee4d005c
......@@ -28,8 +28,7 @@ PimSettingExporterConfigureDialog::PimSettingExporterConfigureDialog(QWidget *pa
: QDialog(parent)
{
setWindowTitle(i18n("Configure PimSettingExporter"));
QVBoxLayout *layout = new QVBoxLayout;
setLayout(layout);
QVBoxLayout *layout = new QVBoxLayout(this);
mConfigureWidget = new PimSettingExporterConfigureWidget(this);
mConfigureWidget->setObjectName(QStringLiteral("configurewidget"));
layout->addWidget(mConfigureWidget);
......
......@@ -40,17 +40,19 @@ ShowArchiveStructureDialog::ShowArchiveStructureDialog(const QString &filename,
mFileName(filename)
{
setWindowTitle(i18n("Show Archive Content on file \"%1\"", filename));
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Close);
QVBoxLayout *mainLayout = new QVBoxLayout;
setLayout(mainLayout);
QPushButton *user1Button = new QPushButton;
buttonBox->addButton(user1Button, QDialogButtonBox::ActionRole);
connect(buttonBox, &QDialogButtonBox::rejected, this, &ShowArchiveStructureDialog::reject);
setModal(true);
mTreeWidget = new QTreeWidget;
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mTreeWidget = new QTreeWidget(this);
mTreeWidget->header()->hide();
mTreeWidget->setAlternatingRowColors(true);
KTreeWidgetSearchLine *searchLine = new KTreeWidgetSearchLine(this, mTreeWidget);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Close, this);
QPushButton *user1Button = new QPushButton;
buttonBox->addButton(user1Button, QDialogButtonBox::ActionRole);
connect(buttonBox, &QDialogButtonBox::rejected, this, &ShowArchiveStructureDialog::reject);
mainLayout->addWidget(searchLine);
mainLayout->addWidget(mTreeWidget);
mainLayout->addWidget(buttonBox);
......
......@@ -33,14 +33,13 @@ SynchronizeResourceDialog::SynchronizeResourceDialog(QWidget *parent)
: QDialog(parent)
{
setWindowTitle(i18n("Synchronize Resources"));
QVBoxLayout *topLayout = new QVBoxLayout;
setLayout(topLayout);
QVBoxLayout *topLayout = new QVBoxLayout(this);
QLabel *lab = new QLabel(i18n("Some resources were added but data were not sync. Select resources that you want to sync:"));
QLabel *lab = new QLabel(i18n("Some resources were added but data were not sync. Select resources that you want to sync:"), this);
lab->setWordWrap(true);
lab->setObjectName(QStringLiteral("label"));
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, this);
buttonBox->setObjectName(QStringLiteral("buttonbox"));
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment