Akonadi Contacts

preferredlineeditwidget.h
1/*
2 This file is part of Contact Editor.
3
4 SPDX-FileCopyrightText: 2016-2024 Laurent Montel <montel@kde.org>
5
6 SPDX-License-Identifier: LGPL-2.0-or-later
7*/
8
9#pragma once
10
11#include <KLineEdit>
12#include <QIcon>
13class QAction;
14namespace Akonadi
15{
16class PreferredLineEditWidget : public KLineEdit
17{
19public:
20 explicit PreferredLineEditWidget(QWidget *parent = nullptr);
21 ~PreferredLineEditWidget() override;
22
23 [[nodiscard]] bool preferred() const;
24
25 void setPreferred(bool preferred);
26
28 void preferredChanged(QWidget *w);
29
30private:
31 void slotPreferredStatusChanged();
32 void updatePreferredIcon();
33 bool mPreferred = false;
34 QIcon mIconEnabled;
35 QIcon mIconDisabled;
36 QAction *mPreferredAction = nullptr;
37};
38}
A widget for editing the display name of a contact.
Q_OBJECTQ_OBJECT
Q_SIGNALSQ_SIGNALS
QObject * parent() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:05:47 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.