Commit 6ab43cfb authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Assign directly parent

parent d8af50a7
......@@ -47,9 +47,8 @@ SendLaterDialog::SendLaterDialog(SendLaterInfo *info, QWidget *parent)
mSendLaterWidget->setupUi(sendLaterWidget);
QWidget *w = new QWidget(this);
QVBoxLayout *lay = new QVBoxLayout;
QVBoxLayout *lay = new QVBoxLayout(w);
lay->setContentsMargins(0, 0, 0, 0);
w->setLayout(lay);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, this);
mOkButton = buttonBox->button(QDialogButtonBox::Ok);
......
......@@ -31,7 +31,7 @@ using namespace MessageComposer;
SendLaterTimeDateWidget::SendLaterTimeDateWidget(QWidget *parent)
: QWidget(parent)
{
QHBoxLayout *lay = new QHBoxLayout;
QHBoxLayout *lay = new QHBoxLayout(this);
lay->setContentsMargins(0, 0, 0, 0);
QDateTime t = QDateTime::currentDateTime();
......@@ -49,8 +49,6 @@ SendLaterTimeDateWidget::SendLaterTimeDateWidget(QWidget *parent)
lay->addWidget(mDateComboBox.get());
lay->addWidget(mTimeComboBox.get());
setLayout(lay);
}
SendLaterTimeDateWidget::~SendLaterTimeDateWidget() = default;
......
......@@ -40,11 +40,10 @@ QuickSearchLine::QuickSearchLine(QWidget *parent)
vbox->setSpacing(0);
QWidget *w = new QWidget;
QHBoxLayout *hbox = new QHBoxLayout;
QHBoxLayout *hbox = new QHBoxLayout(w);
hbox->setContentsMargins(0, 0, 0, 0);
hbox->setSpacing(0);
w->setLayout(hbox);
vbox->addWidget(w);
mSearchEdit = new SearchLineStatus(this);
connect(mSearchEdit, &SearchLineStatus::filterActionChanged, this, &QuickSearchLine::slotFilterActionChanged);
......
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