File indexing completed on 2024-11-24 04:43:04
0001 /* 0002 SPDX-FileCopyrightText: 2014-2024 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include <Akonadi/Item> 0010 #include <QDialog> 0011 0012 #include "kaddressbookmergelib_export.h" 0013 #include "searchduplicateresultwidget.h" 0014 class QStackedWidget; 0015 namespace KABMergeContacts 0016 { 0017 class SearchDuplicateResultWidget; 0018 class MergeContactShowResultTabWidget; 0019 class MergeContactSelectInformationTabWidget; 0020 class MergeContactErrorLabel; 0021 0022 class KADDRESSBOOKMERGELIB_EXPORT SearchAndMergeContactDuplicateContactDialog : public QDialog 0023 { 0024 Q_OBJECT 0025 public: 0026 explicit SearchAndMergeContactDuplicateContactDialog(QWidget *parent = nullptr); 0027 ~SearchAndMergeContactDuplicateContactDialog() override; 0028 0029 void searchPotentialDuplicateContacts(const Akonadi::Item::List &list); 0030 0031 private: 0032 void slotDuplicateFound(const QList<Akonadi::Item::List> &duplicate); 0033 void slotMergeDone(); 0034 void slotContactMerged(const Akonadi::Item &item); 0035 void slotCustomizeMergeContacts(const QList<KABMergeContacts::MergeConflictResult> &lst, const Akonadi::Collection &col); 0036 void readConfig(); 0037 void writeConfig(); 0038 SearchDuplicateResultWidget *const mSearchResult; 0039 MergeContactShowResultTabWidget *const mMergeContactResult; 0040 KABMergeContacts::MergeContactErrorLabel *const mNoContactSelected; 0041 KABMergeContacts::MergeContactErrorLabel *const mNoDuplicateContactFound; 0042 KABMergeContacts::MergeContactErrorLabel *const mNoEnoughContactSelected; 0043 KABMergeContacts::MergeContactSelectInformationTabWidget *const mSelectInformation; 0044 QStackedWidget *const mStackedWidget; 0045 }; 0046 }