• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeutils API Reference
  • KDE Home
  • Contact Us
 

kgpg

  • sources
  • kde-4.14
  • kdeutils
  • kgpg
  • model
gpgservermodel.h
Go to the documentation of this file.
1 /* Copyright 2014 Rolf Eike Beer <kde@opensource.sf-tec.de>
2  *
3  * This program is free software; you can redistribute it and/or
4  * modify it under the terms of the GNU General Public License as
5  * published by the Free Software Foundation; either version 2 of
6  * the License or (at your option) version 3 or any later version
7  * accepted by the membership of KDE e.V. (or its successor approved
8  * by the membership of KDE e.V.), which shall act as a proxy
9  * defined in Section 14 of version 3 of the license.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program. If not, see <http://www.gnu.org/licenses/>.
18  */
19 #ifndef GPGSERVERMODEL_H
20 #define GPGSERVERMODEL_H
21 
22 #include <QStringListModel>
23 
27 class GpgServerModel: public QStringListModel {
28  Q_OBJECT
29 public:
30  GpgServerModel(QObject *parent = NULL);
31  virtual ~GpgServerModel();
32 
33  void setDefault(const QString &server);
34  void setDefault(const int index);
35 
39  int defaultRow() const;
40 
45  QString defaultServer() const;
46 
47  virtual QVariant data(const QModelIndex &index, int role) const;
48 
49 private slots:
50  void slotRowsRemoved(const QModelIndex &, int start, int end);
51 
52 private:
53  int m_defaultRow;
54 };
55 
56 #endif
QModelIndex
GpgServerModel::defaultServer
QString defaultServer() const
returns the URL of the default server
Definition: gpgservermodel.cpp:75
GpgServerModel::~GpgServerModel
virtual ~GpgServerModel()
Definition: gpgservermodel.cpp:32
GpgServerModel
model holding the configured GnuPG key servers
Definition: gpgservermodel.h:27
GpgServerModel::setDefault
void setDefault(const QString &server)
Definition: gpgservermodel.cpp:53
QObject
QAbstractListModel::index
virtual QModelIndex index(int row, int column, const QModelIndex &parent) const
GpgServerModel::GpgServerModel
GpgServerModel(QObject *parent=NULL)
Definition: gpgservermodel.cpp:25
QString
QStringListModel
GpgServerModel::defaultRow
int defaultRow() const
returns the row of the current default keyserver
Definition: gpgservermodel.cpp:65
GpgServerModel::data
virtual QVariant data(const QModelIndex &index, int role) const
Definition: gpgservermodel.cpp:86
QObject::parent
QObject * parent() const
QVariant
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:42:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kgpg

Skip menu "kgpg"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeutils API Reference

Skip menu "kdeutils API Reference"
  • ark
  • filelight
  • kcalc
  • kcharselect
  • kdf
  • kfloppy
  • kgpg
  • ktimer
  • kwallet
  • sweeper

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal