summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergio Martins <[email protected]>2015-08-09 09:17:16 +0100
committerSergio Martins <[email protected]>2015-08-09 10:19:42 +0100
commit1eb0b3e3b568fccfa6c31bfb69e289b6c7d26986 (patch)
tree0c918e4d2d8393273b611482ae59e60e114c3d1d
parent8063d971cee226f85f9842809300345d24794bb4 (diff)
Remove unused static globals
-rw-r--r--kleopatra/conf/dirservconfigpage.cpp2
-rw-r--r--kleopatra/kgpgconf/configreader.cpp12
-rw-r--r--kleopatra/mainwindow_desktop.cpp6
-rw-r--r--kleopatra/models/keycache.cpp2
-rw-r--r--kleopatra/smartcard/readerstatus.cpp1
-rw-r--r--kleopatra/uiserver/selectcertificatecommand.cpp2
-rw-r--r--libkleo/backends/qgpgme/qgpgmecryptoconfig.cpp4
-rw-r--r--messagelist/core/optionset.cpp2
-rw-r--r--messagelist/core/view.cpp4
-rw-r--r--messageviewer/viewer/bodypartformatter.cpp3
10 files changed, 12 insertions, 26 deletions
diff --git a/kleopatra/conf/dirservconfigpage.cpp b/kleopatra/conf/dirservconfigpage.cpp
index b383931..fce8574 100644
--- a/kleopatra/conf/dirservconfigpage.cpp
+++ b/kleopatra/conf/dirservconfigpage.cpp
@@ -148,9 +148,11 @@ static const char s_maxitems_componentName[] = "dirmngr";
static const char s_maxitems_groupName[] = "LDAP";
static const char s_maxitems_entryName[] = "max-replies";
+#ifdef NOT_USEFUL_CURRENTLY
static const char s_addnewservers_componentName[] = "dirmngr";
static const char s_addnewservers_groupName[] = "LDAP";
static const char s_addnewservers_entryName[] = "add-servers";
+#endif
DirectoryServicesConfigurationPage::DirectoryServicesConfigurationPage(QWidget *parent, const QVariantList &args)
: KCModule(parent, args)
diff --git a/kleopatra/kgpgconf/configreader.cpp b/kleopatra/kgpgconf/configreader.cpp
index 83e000e..6f3b273 100644
--- a/kleopatra/kgpgconf/configreader.cpp
+++ b/kleopatra/kgpgconf/configreader.cpp
@@ -60,13 +60,13 @@ struct GpgConfResult {
};
static const int GPGCONF_FLAG_GROUP = 1;
-static const int GPGCONF_FLAG_OPTIONAL = 2;
+//static const int GPGCONF_FLAG_OPTIONAL = 2;
static const int GPGCONF_FLAG_LIST = 4;
-static const int GPGCONF_FLAG_RUNTIME = 8;
-static const int GPGCONF_FLAG_DEFAULT = 16; // fixed default value available
-static const int GPGCONF_FLAG_DEFAULT_DESC = 32; // runtime default value available
-static const int GPGCONF_FLAG_NOARG_DESC = 64; // option with optional arg; special meaning if no arg set
-static const int GPGCONF_FLAG_NO_CHANGE = 128; // readonly
+//static const int GPGCONF_FLAG_RUNTIME = 8;
+//static const int GPGCONF_FLAG_DEFAULT = 16; // fixed default value available
+//static const int GPGCONF_FLAG_DEFAULT_DESC = 32; // runtime default value available
+//static const int GPGCONF_FLAG_NOARG_DESC = 64; // option with optional arg; special meaning if no arg set
+//static const int GPGCONF_FLAG_NO_CHANGE = 128; // readonly
// Change size of mFlags bitfield if adding new values here
// gpgconf arg type number -> CryptoConfigEntry arg type enum mapping
diff --git a/kleopatra/mainwindow_desktop.cpp b/kleopatra/mainwindow_desktop.cpp
index 3098d7a..efc8001 100644
--- a/kleopatra/mainwindow_desktop.cpp
+++ b/kleopatra/mainwindow_desktop.cpp
@@ -97,12 +97,6 @@
#include <vector>
#include <KSharedConfig>
-#ifdef Q_OS_WIN32
-static const bool OS_WIN = true;
-#else
-static const bool OS_WIN = false;
-#endif
-
using namespace Kleo;
using namespace Kleo::Commands;
using namespace boost;
diff --git a/kleopatra/models/keycache.cpp b/kleopatra/models/keycache.cpp
index f583119..ae0444e 100644
--- a/kleopatra/models/keycache.cpp
+++ b/kleopatra/models/keycache.cpp
@@ -572,8 +572,6 @@ std::vector<Key> KeyCache::findSubjects(std::vector<Key>::const_iterator first,
return result;
}
-static const unsigned int LIKELY_CHAIN_DEPTH = 3;
-
std::vector<Key> KeyCache::findIssuers(const Key &key, Options options) const
{
diff --git a/kleopatra/smartcard/readerstatus.cpp b/kleopatra/smartcard/readerstatus.cpp
index d350544..e227c5c 100644
--- a/kleopatra/smartcard/readerstatus.cpp
+++ b/kleopatra/smartcard/readerstatus.cpp
@@ -78,7 +78,6 @@ using namespace Kleo::SmartCard;
using namespace GpgME;
using namespace boost;
-static const unsigned int RETRY_WAIT = 2; // seconds
static const unsigned int CHECK_INTERVAL = 2000; // msecs
static ReaderStatus *self = 0;
diff --git a/kleopatra/uiserver/selectcertificatecommand.cpp b/kleopatra/uiserver/selectcertificatecommand.cpp
index f55c405..3b59136 100644
--- a/kleopatra/uiserver/selectcertificatecommand.cpp
+++ b/kleopatra/uiserver/selectcertificatecommand.cpp
@@ -61,8 +61,6 @@ using namespace Kleo::Dialogs;
using namespace GpgME;
using namespace boost;
-static const char option_prefix[] = "prefix";
-
class SelectCertificateCommand::Private
{
friend class ::Kleo::SelectCertificateCommand;
diff --git a/libkleo/backends/qgpgme/qgpgmecryptoconfig.cpp b/libkleo/backends/qgpgme/qgpgmecryptoconfig.cpp
index 7d8aca6..9c64053 100644
--- a/libkleo/backends/qgpgme/qgpgmecryptoconfig.cpp
+++ b/libkleo/backends/qgpgme/qgpgmecryptoconfig.cpp
@@ -60,8 +60,8 @@ static const int GPGCONF_FLAG_OPTIONAL = 2;
static const int GPGCONF_FLAG_LIST = 4;
static const int GPGCONF_FLAG_RUNTIME = 8;
static const int GPGCONF_FLAG_DEFAULT = 16; // fixed default value available
-static const int GPGCONF_FLAG_DEFAULT_DESC = 32; // runtime default value available
-static const int GPGCONF_FLAG_NOARG_DESC = 64; // option with optional arg; special meaning if no arg set
+//static const int GPGCONF_FLAG_DEFAULT_DESC = 32; // runtime default value available
+//static const int GPGCONF_FLAG_NOARG_DESC = 64; // option with optional arg; special meaning if no arg set
static const int GPGCONF_FLAG_NO_CHANGE = 128; // readonly
// Change size of mFlags bitfield if adding new values here
diff --git a/messagelist/core/optionset.cpp b/messagelist/core/optionset.cpp
index 9da6d6e..3ef5498 100644
--- a/messagelist/core/optionset.cpp
+++ b/messagelist/core/optionset.cpp
@@ -27,8 +27,6 @@
static const int gOptionSetInitialMarker = 0xcafe; // don't change
static const int gOptionSetFinalMarker = 0xbabe; // don't change
-static const int gOptionSetCurrentVersion = 0x1001; // increase if you add new fields of change the meaning of some
-
static const int gOptionSetWithReadOnLyModeVersion = 0x1002;
using namespace MessageList::Core;
diff --git a/messagelist/core/view.cpp b/messagelist/core/view.cpp
index 4f301a7..d3c95af 100644
--- a/messagelist/core/view.cpp
+++ b/messagelist/core/view.cpp
@@ -740,10 +740,6 @@ void View::showEvent(QShowEvent *e)
}
}
-const int gHeaderContextMenuAdjustColumnSizesId = -1;
-const int gHeaderContextMenuShowDefaultColumnsId = -2;
-const int gHeaderContextMenuDisplayToolTipsId = -3;
-
void View::slotHeaderContextMenuRequested(const QPoint &pnt)
{
if (!d->mTheme) {
diff --git a/messageviewer/viewer/bodypartformatter.cpp b/messageviewer/viewer/bodypartformatter.cpp
index 3252901..176c8e6 100644
--- a/messageviewer/viewer/bodypartformatter.cpp
+++ b/messageviewer/viewer/bodypartformatter.cpp
@@ -147,7 +147,7 @@ struct SubtypeBuiltin {
const char *subtype;
BodyPartFormatterCreator create;
};
-
+/*
static const SubtypeBuiltin applicationSubtypeBuiltins[] = {
{ "octet-stream", &ApplicationOctetStreamBodyPartFormatter::create },
{ "pkcs7-mime", &ApplicationPkcs7MimeBodyPartFormatter::create },
@@ -210,6 +210,7 @@ static const struct {
};
#undef DIM
+*/
static const BodyPartFormatter *createForText(const char *subtype)
{