Mercurial > trustbridge
diff ui/createinstallerdialog.cpp @ 428:d1819cd56dee
Updated dialog layout.
author | Raimund Renkert <rrenkert@intevation.de> |
---|---|
date | Thu, 17 Apr 2014 13:16:43 +0200 |
parents | d7cda835abd6 |
children | 9d3880db6ba7 |
line wrap: on
line diff
--- a/ui/createinstallerdialog.cpp Thu Apr 17 12:56:23 2014 +0200 +++ b/ui/createinstallerdialog.cpp Thu Apr 17 13:16:43 2014 +0200 @@ -29,11 +29,11 @@ QVBoxLayout *topLayout = new QVBoxLayout; QVBoxLayout *headerLayout = new QVBoxLayout; QHBoxLayout *headerSubLayout = new QHBoxLayout; - QVBoxLayout *centerLayout = new QVBoxLayout; + QHBoxLayout *centerLayout = new QHBoxLayout; QHBoxLayout *bottomLayout = new QHBoxLayout; - QHBoxLayout *archiveLayout = new QHBoxLayout; - QHBoxLayout *certLayout = new QHBoxLayout; - QHBoxLayout *saveLayout = new QHBoxLayout; + QVBoxLayout *labelLayout = new QVBoxLayout; + QVBoxLayout *fieldLayout = new QVBoxLayout; + QVBoxLayout *buttonLayout = new QVBoxLayout; QLabel *header = new QLabel("<h3>" + tr("Create binary installer") + "</h3>"); QLabel *description = new QLabel( @@ -46,42 +46,38 @@ headerLayout->addWidget(header); headerLayout->addLayout(headerSubLayout); headerLayout->addWidget(headerSeparator); + headerLayout->insertSpacing(4, 10); QLabel *archiveLabel = new QLabel(tr("Select source archive:")); - archiveLabel->setFixedWidth(225); + QLabel *certLabel = new QLabel(tr("Select code signing certificate (secret key):")); + QLabel *saveLabel = new QLabel(tr("Select output folder:")); + labelLayout->addWidget(archiveLabel); + labelLayout->addWidget(certLabel); + labelLayout->addWidget(saveLabel); + mArchiveFile = new QLineEdit(); + mCertFile = new QLineEdit(); + mSaveFile = new QLineEdit(); + fieldLayout->addWidget(mArchiveFile); + fieldLayout->addWidget(mCertFile); + fieldLayout->addWidget(mSaveFile); + QPushButton *archiveSelect = new QPushButton("..."); connect(archiveSelect, SIGNAL(clicked()), this, SLOT(openArchiveSelect())); archiveSelect->setFixedWidth(30); - archiveLayout->addWidget(archiveLabel); - archiveLayout->addWidget(mArchiveFile); - archiveLayout->addWidget(archiveSelect); - - QLabel *certLabel = new QLabel(tr("Select code signing certificate (secret key):")); - certLabel->setFixedWidth(225); - mCertFile = new QLineEdit(); QPushButton *certSelect = new QPushButton("..."); connect(certSelect, SIGNAL(clicked()), this, SLOT(openCertificateSelect())); certSelect->setFixedWidth(30); - certLayout->addWidget(certLabel); - certLayout->addWidget(mCertFile); - certLayout->addWidget(certSelect); - - QLabel *saveLabel = new QLabel(tr("Select output folder:")); - saveLabel->setFixedWidth(225); - mSaveFile = new QLineEdit(); QPushButton *saveSelect = new QPushButton("..."); connect(saveSelect, SIGNAL(clicked()), this, SLOT(openSaveLocation())); saveSelect->setFixedWidth(30); - saveLayout->addWidget(saveLabel); - saveLayout->addWidget(mSaveFile); - saveLayout->addWidget(saveSelect); + buttonLayout->addWidget(archiveSelect); + buttonLayout->addWidget(certSelect); + buttonLayout->addWidget(saveSelect); - centerLayout->insertSpacing(0, 10); - centerLayout->addLayout(archiveLayout); - centerLayout->addLayout(certLayout); - centerLayout->addLayout(saveLayout); - centerLayout->insertSpacing(4, 10); + centerLayout->addLayout(labelLayout); + centerLayout->addLayout(fieldLayout); + centerLayout->addLayout(buttonLayout); QPushButton *create = new QPushButton(tr("Create installer")); connect(create, SIGNAL(clicked()), this, SLOT(createInstaller())); @@ -98,6 +94,7 @@ topLayout->addLayout(headerLayout); topLayout->addLayout(centerLayout); topLayout->insertStretch(2, 10); + centerLayout->insertSpacing(3, 10); topLayout->addWidget(bottomSeparator); topLayout->addLayout(bottomLayout);