• Skip to content
  • Skip to link menu
KDE API Documentation - mergecontactswidget.h Source File (KPeople)
  • KDE Home
  • Contact Us
 

KPeople

  • frameworks
  • kpeople
  • src
  • widgets
  • plugins
mergecontactswidget.h
1 /*
2  Copyright (C) 2013 Franck Arrecot <franck.arrecot@gmail.com>
3 
4  This library is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Lesser General Public
6  License as published by the Free Software Foundation; either
7  version 2.1 of the License, or (at your option) any later version.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Lesser General Public License for more details.
13 
14  You should have received a copy of the GNU Lesser General Public
15  License along with this library; if not, write to the Free Software
16  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18 
19 #ifndef MERGE_CONTACT_WIDGET_H
20 #define MERGE_CONTACT_WIDGET_H
21 
22 #include "abstractpersondetailswidget.h"
23 
24 #include "QPersistentModelIndex"
25 
26 class QPushButton;
27 class PersonPresentationWidget;
28 
29 namespace KPeople
30 {
31 class DuplicatesFinder;
32 }
33 
34 class MergeContactsWidget : public KPeople::AbstractPersonDetailsWidget
35 {
36  Q_OBJECT
37 public:
38  explicit MergeContactsWidget(QWidget *parent, const QVariantList &args);
39  void setPerson(KPeople::PersonData *person);
40  void setPersonsModel(KPeople::PersonsModel *model);
41 
42  void searchForDuplicates();
43  void fillDuplicatesWidget(const QList<QPersistentModelIndex> &duplicates);
44 
45  QList<QPersistentModelIndex> duplicateBusterFromPerson(const QUrl &uri) const;
46  QList<QPersistentModelIndex> getContactsCheckedToMerge() const;
47 
48 private Q_SLOTS:
49  void onMergeButtonPressed();
50  void onMergePossibilitiesButtonPressed();
51  void searchForDuplicatesFinished();
52 private:
53  KPeople::PersonData *m_person;
54  KPeople::PersonsModel *m_model;
55  QPushButton *m_mergeButton;
56 
57  QWidget *m_containerListDetails;
58  KPeople::DuplicatesFinder *m_duplicatesBuster;
59  QList< QPair<QPersistentModelIndex, PersonPresentationWidget *> > m_listMergeContacts;
60 };
61 
62 #endif // MERGE_CONTACT_WIDGET_H
KPeople::PersonData
Allows to query the information about a given person.
Definition: persondata.h:44
KPeople
The KPeople namespace contains all the classes for Libkpeople.
KPeople::PersonsModel
This class creates a model of all known contacts from all sources Contacts are represented as a tree ...
Definition: personsmodel.h:42
This file is part of the KDE documentation.
Documentation copyright © 1996-2015 The KDE developers.
Generated on Fri Feb 13 2015 15:16:39 by doxygen 1.8.9.1 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KPeople

Skip menu "KPeople"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • File List

Class Picker

Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal