diff options
author | Thorbjørn Martsum <tmartsum@gmail.com> | 2013-08-08 16:23:20 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-08-22 06:47:19 +0200 |
commit | e7168ff9fe61a8413d9dc5f7ffe10df843c16184 (patch) | |
tree | 5b6a5df6c6e2b83e303051bb4b77493c85288bae /src/widgets/dialogs | |
parent | 5ba72276c48aafd3179cf96a32eedfe8cc68646d (diff) |
QMessageBox - merge some mac and non-mac code
I have not located any significant behavior changes in this,
and it is annoying having too much similar code in different
branches.
The main change is a removal of Qt::AlignLeft, but
the icon Label should be in its own column.
Change-Id: Iaf07fc503075e61e2af1a93d5fc9e6e34a24451d
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Diffstat (limited to 'src/widgets/dialogs')
-rw-r--r-- | src/widgets/dialogs/qmessagebox.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/widgets/dialogs/qmessagebox.cpp b/src/widgets/dialogs/qmessagebox.cpp index 2467f07d91..65b623d7e9 100644 --- a/src/widgets/dialogs/qmessagebox.cpp +++ b/src/widgets/dialogs/qmessagebox.cpp @@ -300,22 +300,18 @@ void QMessageBoxPrivate::setupLayout() Q_Q(QMessageBox); delete q->layout(); QGridLayout *grid = new QGridLayout; -#ifndef Q_OS_MAC grid->addWidget(iconLabel, 0, 0, 2, 1, Qt::AlignTop); grid->addWidget(label, 0, 1, 1, 1); - // -- leave space for information label -- +#ifndef Q_OS_MAC grid->addWidget(buttonBox, 2, 0, 1, 2); #else + grid->addWidget(buttonBox, 3, 1, 1, 1); grid->setMargin(0); grid->setVerticalSpacing(8); grid->setHorizontalSpacing(0); q->setContentsMargins(24, 15, 24, 20); - grid->addWidget(iconLabel, 0, 0, 2, 1, Qt::AlignTop | Qt::AlignLeft); - grid->addWidget(label, 0, 1, 1, 1); - // -- leave space for information label -- grid->setRowStretch(1, 100); grid->setRowMinimumHeight(2, 6); - grid->addWidget(buttonBox, 3, 1, 1, 1); #endif grid->setSizeConstraint(QLayout::SetNoConstraint); |