KIdentityManagement

identitytreesortproxymodel.h
1// SPDX-FileCopyrightText: 2024 Laurent Montel <montel@kde.org>
2// SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
3
4#pragma once
5#include "kidentitymanagementcore_export.h"
6
7#include <QSortFilterProxyModel>
8
9namespace KIdentityManagementCore
10{
11class IdentityActivitiesAbstract;
12class KIDENTITYMANAGEMENTCORE_EXPORT IdentityTreeSortProxyModel : public QSortFilterProxyModel
13{
14 Q_OBJECT
15public:
16 explicit IdentityTreeSortProxyModel(QObject *parent);
17 ~IdentityTreeSortProxyModel() override;
18
19 [[nodiscard]] IdentityActivitiesAbstract *identityActivitiesAbstract() const;
20 void setIdentityActivitiesAbstract(IdentityActivitiesAbstract *newIdentityActivitiesAbstract);
21
22 [[nodiscard]] bool enablePlasmaActivities() const;
23 void setEnablePlasmaActivities(bool newEnablePlasmaActivities);
24
25protected:
26 [[nodiscard]] bool filterAcceptsRow(int source_row, const QModelIndex &source_parent) const override;
27
28private:
29 IdentityActivitiesAbstract *mIdentityActivitiesAbstract = nullptr;
30 bool mEnablePlasmaActivities = false;
31};
32}
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:18:05 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.