MailTransport

transporttreedelegate.h
1/*
2 SPDX-FileCopyrightText: 2024 Laurent Montel <montel@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8#include "kmailtransport_private_export.h"
9#include <QStyledItemDelegate>
10class QLineEdit;
11namespace MailTransport
12{
13class KMAILTRANSPORT_TESTS_EXPORT TransportTreeDelegate : public QStyledItemDelegate
14{
15 Q_OBJECT
16public:
17 explicit TransportTreeDelegate(QObject *parent = nullptr);
18 ~TransportTreeDelegate() override;
19
20 [[nodiscard]] QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const override;
21 void setEditorData(QWidget *editor, const QModelIndex &index) const override;
22 void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const override;
23 void updateEditorGeometry(QWidget *editor, const QStyleOptionViewItem &option, const QModelIndex &) const override;
24
25private:
26 QLineEdit *mLineEdit = nullptr;
27};
28}
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:07:33 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.