Commit 2b0c2e9c authored by Laurent Montel's avatar Laurent Montel
Browse files

const'ify++

parent 7fa37d45
Pipeline #219523 passed with stage
in 27 minutes and 34 seconds
......@@ -37,10 +37,10 @@ private:
void writeConfig();
SearchDuplicateResultWidget *const mSearchResult;
MergeContactShowResultTabWidget *const mMergeContactResult;
KABMergeContacts::MergeContactErrorLabel *mNoContactSelected = nullptr;
KABMergeContacts::MergeContactErrorLabel *mNoDuplicateContactFound = nullptr;
KABMergeContacts::MergeContactErrorLabel *mNoEnoughContactSelected = nullptr;
KABMergeContacts::MergeContactSelectInformationTabWidget *mSelectInformation = nullptr;
QStackedWidget *mStackedWidget = nullptr;
KABMergeContacts::MergeContactErrorLabel *const mNoContactSelected;
KABMergeContacts::MergeContactErrorLabel *const mNoDuplicateContactFound;
KABMergeContacts::MergeContactErrorLabel *const mNoEnoughContactSelected;
KABMergeContacts::MergeContactSelectInformationTabWidget *const mSelectInformation;
QStackedWidget *const mStackedWidget;
};
}
......@@ -25,6 +25,9 @@ KADDRESSBOOKMERGELIB_EXPORT QAbstractItemModel *_k_searchDuplicateResultStubMode
using namespace KABMergeContacts;
SearchDuplicateResultWidget::SearchDuplicateResultWidget(QWidget *parent)
: QWidget(parent)
, mResult(new ResultDuplicateTreeWidget(this))
, mContactViewer(new KAddressBookGrantlee::GrantleeContactViewer(this))
, mMergeContactWarning(new MergeContactLoseInformationWarning(this))
{
auto mainLayout = new QVBoxLayout(this);
mainLayout->setContentsMargins({});
......@@ -33,15 +36,12 @@ SearchDuplicateResultWidget::SearchDuplicateResultWidget(QWidget *parent)
splitter->setObjectName(QStringLiteral("splitter"));
splitter->setChildrenCollapsible(false);
mainLayout->addWidget(splitter);
mResult = new ResultDuplicateTreeWidget(this);
mResult->setObjectName(QStringLiteral("result_treewidget"));
mContactViewer = new KAddressBookGrantlee::GrantleeContactViewer(this);
mContactViewer->setObjectName(QStringLiteral("contact_viewer"));
splitter->addWidget(mResult);
splitter->addWidget(mContactViewer);
connect(mResult, &ResultDuplicateTreeWidget::showContactPreview, mContactViewer, &KAddressBookGrantlee::GrantleeContactViewer::setContact);
mMergeContactWarning = new MergeContactLoseInformationWarning(this);
mMergeContactWarning->setObjectName(QStringLiteral("mergecontactwarning"));
connect(mMergeContactWarning, &MergeContactLoseInformationWarning::continueMerging, this, &SearchDuplicateResultWidget::slotAutomaticMerging);
connect(mMergeContactWarning,
......
......@@ -52,11 +52,11 @@ private:
void mergeContact();
QVector<MergeConflictResult> mResultConflictList;
QVector<Akonadi::Item::List> mListContactToMerge;
ResultDuplicateTreeWidget *mResult = nullptr;
KAddressBookGrantlee::GrantleeContactViewer *mContactViewer = nullptr;
ResultDuplicateTreeWidget *const mResult;
KAddressBookGrantlee::GrantleeContactViewer *const mContactViewer;
QPushButton *mMergeContact = nullptr;
Akonadi::CollectionComboBox *mCollectionCombobox = nullptr;
MergeContactLoseInformationWarning *mMergeContactWarning = nullptr;
MergeContactLoseInformationWarning *const mMergeContactWarning;
int mIndexListContact = 0;
};
}
......
Supports Markdown
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