Akonadi Contacts

contacteditorpageplugin.h
1/*
2 This file is part of Contact Editor.
3
4 SPDX-FileCopyrightText: 2009 Tobias Koenig <tokoe@kde.org>
5
6 SPDX-License-Identifier: LGPL-2.0-or-later
7*/
8
9#pragma once
10
11#include <QWidget>
12
13namespace KContacts
14{
15class Addressee;
16}
17
18namespace Akonadi
19{
20/**
21 * @short The base class for custom ContactEditor page plugins.
22 *
23 * @author Tobias Koenig <tokoe@kde.org>
24 * @since 4.4
25 */
27{
28public:
29 /**
30 * Returns the i18n'd page title.
31 */
32 virtual QString title() const = 0;
33
34 /**
35 * This method is called to fill the editor widget with the data from @p contact.
36 */
37 virtual void loadContact(const KContacts::Addressee &contact) = 0;
38
39 /**
40 * This method is called to store the data from the editor widget into @p contact.
41 */
42 virtual void storeContact(KContacts::Addressee &contact) const = 0;
43
44 /**
45 * This method is called to set the editor widget @p readOnly.
46 */
47 virtual void setReadOnly(bool readOnly) = 0;
48};
49}
50
51Q_DECLARE_INTERFACE(Akonadi::ContactEditorPagePlugin, "org.freedesktop.Akonadi.ContactEditorPagePlugin/1.0")
The base class for custom ContactEditor page plugins.
virtual void loadContact(const KContacts::Addressee &contact)=0
This method is called to fill the editor widget with the data from contact.
virtual void setReadOnly(bool readOnly)=0
This method is called to set the editor widget readOnly.
virtual void storeContact(KContacts::Addressee &contact) const =0
This method is called to store the data from the editor widget into contact.
virtual QString title() const =0
Returns the i18n'd page title.
A widget for editing the display name of a contact.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:13:20 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.