Commit 20951cc0 authored by Laurent Montel's avatar Laurent Montel 😁

Clean up

parent dc851cf2
......@@ -35,9 +35,7 @@ class Item;
using namespace Akonadi;
RelationSync::RelationSync(QObject *parent)
: Job(parent),
mRemoteRelationsSet(false),
mLocalRelationsFetched(false)
: Job(parent)
{
}
......
......@@ -50,8 +50,8 @@ private:
private:
Akonadi::Relation::List mRemoteRelations;
Akonadi::Relation::List mLocalRelations;
bool mRemoteRelationsSet;
bool mLocalRelationsFetched;
bool mRemoteRelationsSet = false;
bool mLocalRelationsFetched = false;
};
}
......
......@@ -33,7 +33,6 @@ public:
: QSharedData()
, condition(SearchTerm::CondEqual)
, relation(SearchTerm::RelAnd)
, isNegated(false)
{
}
......@@ -63,7 +62,7 @@ public:
Condition condition;
Relation relation;
QList<SearchTerm> terms;
bool isNegated;
bool isNegated = false;
};
class SearchQuery::Private : public QSharedData
......
......@@ -54,7 +54,6 @@ public:
: instance(new ServerManager(this))
, mState(ServerManager::NotRunning)
, mSafetyTimer(new QTimer)
, mFirstRunner(nullptr)
{
mState = instance->state();
mSafetyTimer->setSingleShot(true);
......@@ -122,12 +121,12 @@ public:
}
}
ServerManager *instance;
ServerManager *instance = nullptr;
static int serverProtocolVersion;
static uint generation;
ServerManager::State mState;
QScopedPointer<QTimer> mSafetyTimer;
Firstrun *mFirstRunner;
Firstrun *mFirstRunner = nullptr;
static Internal::ClientType clientType;
QString mBrokenReason;
};
......
......@@ -27,8 +27,6 @@ class Q_DECL_HIDDEN TagAttribute::Private
{
public:
Private()
: inToolbar(false)
, priority(-1)
{
}
......@@ -37,9 +35,9 @@ public:
QColor backgroundColor;
QColor textColor;
QString font;
bool inToolbar;
bool inToolbar = false;
QString shortcut;
int priority;
int priority = -1;
};
TagAttribute::TagAttribute()
......@@ -95,6 +93,7 @@ TagAttribute *TagAttribute::clone() const
QByteArray TagAttribute::serialized() const
{
QList<QByteArray> l;
l.reserve(8);
l << ImapParser::quote(d->name.toUtf8());
l << ImapParser::quote(d->icon.toUtf8());
l << ImapParser::quote(d->font.toUtf8());
......
......@@ -24,12 +24,11 @@ using namespace Akonadi;
struct Q_DECL_HIDDEN Akonadi::TagFetchScope::Private {
Private()
: mFetchIdOnly(false)
{
}
QSet<QByteArray> mAttributes;
bool mFetchIdOnly;
bool mFetchIdOnly = false;
};
TagFetchScope::TagFetchScope()
......
......@@ -70,11 +70,12 @@ QString DBus::parseAgentServiceName(const QString &serviceName, DBus::AgentType
if ((parts.size() == 2 && !Akonadi::Instance::hasIdentifier())
|| (parts.size() == 3 && Akonadi::Instance::hasIdentifier() && Akonadi::Instance::identifier() == parts.at(2))) {
// switch on parts.at( 0 )
if (parts.first() == QLatin1String("Agent")) {
const QString &partFirst = parts.constFirst();
if (partFirst == QLatin1String("Agent")) {
agentType = Agent;
} else if (parts.first() == QLatin1String("Resource")) {
} else if (partFirst == QLatin1String("Resource")) {
agentType = Resource;
} else if (parts.first() == QLatin1String("Preprocessor")) {
} else if (partFirst == QLatin1String("Preprocessor")) {
agentType = Preprocessor;
} else {
return QString();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment