Page Menu
Home
GnuPG
Search
Configure Global Search
Log In
Files
F34085807
keylistsortfilterproxymodel.h
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Size
1 KB
Subscribers
None
keylistsortfilterproxymodel.h
View Options
/* -*- mode: c++; c-basic-offset:4 -*-
models/keylistsortfilterproxymodel.h
This file is part of Kleopatra, the KDE keymanager
SPDX-FileCopyrightText: 2007 Klarälvdalens Datakonsult AB
SPDX-License-Identifier: GPL-2.0-or-later
*/
#pragma once
#include
"keylistmodelinterface.h"
#include
"kleo_export.h"
#include
<QSortFilterProxyModel>
#include
<memory>
namespace
GpgME
{
class
Key
;
}
namespace
Kleo
{
class
KeyFilter
;
class
KLEO_EXPORT
AbstractKeyListSortFilterProxyModel
:
public
QSortFilterProxyModel
,
public
KeyListModelInterface
{
Q_OBJECT
protected
:
AbstractKeyListSortFilterProxyModel
(
const
AbstractKeyListSortFilterProxyModel
&
);
public
:
explicit
AbstractKeyListSortFilterProxyModel
(
QObject
*
parent
=
nullptr
);
~
AbstractKeyListSortFilterProxyModel
()
override
;
virtual
AbstractKeyListSortFilterProxyModel
*
clone
()
const
=
0
;
GpgME
::
Key
key
(
const
QModelIndex
&
idx
)
const
override
;
std
::
vector
<
GpgME
::
Key
>
keys
(
const
QList
<
QModelIndex
>
&
indexes
)
const
override
;
KeyGroup
group
(
const
QModelIndex
&
idx
)
const
override
;
using
QAbstractItemModel
::
index
;
QModelIndex
index
(
const
GpgME
::
Key
&
key
)
const
override
;
QList
<
QModelIndex
>
indexes
(
const
std
::
vector
<
GpgME
::
Key
>
&
keys
)
const
override
;
QModelIndex
index
(
const
KeyGroup
&
group
)
const
override
;
private
:
void
init
();
};
class
KLEO_EXPORT
KeyListSortFilterProxyModel
:
public
AbstractKeyListSortFilterProxyModel
{
Q_OBJECT
protected
:
KeyListSortFilterProxyModel
(
const
KeyListSortFilterProxyModel
&
);
public
:
explicit
KeyListSortFilterProxyModel
(
QObject
*
parent
=
nullptr
);
~
KeyListSortFilterProxyModel
()
override
;
std
::
shared_ptr
<
const
KeyFilter
>
keyFilter
()
const
;
void
setKeyFilter
(
const
std
::
shared_ptr
<
const
KeyFilter
>
&
kf
);
KeyListSortFilterProxyModel
*
clone
()
const
override
;
protected
:
bool
filterAcceptsRow
(
int
source_row
,
const
QModelIndex
&
source_parent
)
const
override
;
private
:
class
Private
;
QScopedPointer
<
Private
>
const
d
;
};
}
File Metadata
Details
Attached
Mime Type
text/x-c++
Expires
Wed, Dec 3, 3:36 AM (1 d, 17 h)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
51/b5/8f1358be61bf47ed0917ae6628d9
Attached To
rLIBKLEO Libkleo
Event Timeline
Log In to Comment