File indexing completed on 2024-11-24 04:39:32

0001 /*
0002     This file is part of Contact Editor.
0003 
0004     SPDX-FileCopyrightText: 2016-2024 Laurent Montel <montel@kde.org>
0005 
0006     SPDX-License-Identifier: LGPL-2.0-or-later
0007 */
0008 
0009 #pragma once
0010 
0011 #include <QWidget>
0012 class DateEditWidget;
0013 class KLineEdit;
0014 namespace KContacts
0015 {
0016 class Addressee;
0017 }
0018 
0019 namespace Akonadi
0020 {
0021 class PersonalEditorWidget : public QWidget
0022 {
0023     Q_OBJECT
0024 public:
0025     explicit PersonalEditorWidget(QWidget *parent = nullptr);
0026     ~PersonalEditorWidget() override;
0027     void loadContact(const KContacts::Addressee &contact);
0028     void storeContact(KContacts::Addressee &contact);
0029     void setReadOnly(bool readOnly);
0030 
0031 private:
0032     DateEditWidget *mBirthdateWidget = nullptr;
0033     DateEditWidget *mAnniversaryWidget = nullptr;
0034     KLineEdit *mPartnerWidget = nullptr;
0035 };
0036 }