Commit bc764c77 authored by Laurent Montel's avatar Laurent Montel 😁

Make it static

parent 4eb99cdd
......@@ -45,7 +45,8 @@ IncidenceAttribute::~IncidenceAttribute()
QByteArray IncidenceAttribute::type() const
{
return "incidence";
static const QByteArray sType( "incidence" );
return sType;
}
Attribute* IncidenceAttribute::clone() const
......
......@@ -53,7 +53,8 @@ QByteArray NoteAlarmAttribute::serialized() const
QByteArray NoteAlarmAttribute::type() const
{
return "NoteAlarmAttribute";
static const QByteArray sType( "NoteAlarmAttribute" );
return sType;
}
void NoteAlarmAttribute::setDateTime(const KDateTime &dateTime)
......
......@@ -111,7 +111,8 @@ QByteArray NoteDisplayAttribute::serialized() const
QByteArray NoteDisplayAttribute::type() const
{
return "NoteDisplayAttribute";
static const QByteArray sType( "NoteDisplayAttribute" );
return sType;
}
void NoteDisplayAttribute::setBackgroundColor(const QColor &color)
......
......@@ -52,7 +52,8 @@ QByteArray NoteLockAttribute::serialized() const
QByteArray NoteLockAttribute::type() const
{
//We can't change this name!
return "KJotsLockAttribute";
static const QByteArray sType( "KJotsLockAttribute" );
return sType;
}
......@@ -40,7 +40,8 @@ Akonadi::Attribute* DavProtocolAttribute::clone() const
QByteArray DavProtocolAttribute::type() const
{
return "davprotocol";
static const QByteArray sType( "davprotocol" );
return sType;
}
QByteArray DavProtocolAttribute::serialized() const
......
......@@ -109,6 +109,7 @@ KCalCore::Alarm::List DefaultReminderAttribute::alarms( KCalCore::Incidence *inc
QByteArray DefaultReminderAttribute::type() const
{
return "defaultReminders";
static const QByteArray sType( "defaultReminders" );
return sType;
}
......@@ -44,7 +44,8 @@ Akonadi::Attribute* HighestModSeqAttribute::clone() const
QByteArray HighestModSeqAttribute::type() const
{
return "highestmodseq";
static const QByteArray sType( "highestmodseq" );
return sType;
}
void HighestModSeqAttribute::deserialize( const QByteArray &data )
......
......@@ -40,7 +40,8 @@ bool NoInferiorsAttribute::noInferiors() const
QByteArray NoInferiorsAttribute::type() const
{
return "noinferiors";
static const QByteArray sType( "noinferiors" );
return sType;
}
Akonadi::Attribute* NoInferiorsAttribute::clone() const
......
......@@ -40,7 +40,8 @@ bool NoSelectAttribute::noSelect() const
QByteArray NoSelectAttribute::type() const
{
return "noselect";
static const QByteArray sType( "noselect" );
return sType;
}
Akonadi::Attribute* NoSelectAttribute::clone() const
......
......@@ -42,7 +42,8 @@ uint TimestampAttribute::timestamp() const
QByteArray TimestampAttribute::type() const
{
return "timestamp";
static const QByteArray sType( "timestamp" );
return sType;
}
Akonadi::Attribute *TimestampAttribute::clone() const
......
......@@ -40,7 +40,8 @@ int UidNextAttribute::uidNext() const
QByteArray UidNextAttribute::type() const
{
return "uidnext";
static const QByteArray sType( "uidnext" );
return sType;
}
Akonadi::Attribute* UidNextAttribute::clone() const
......
......@@ -40,7 +40,8 @@ int UidValidityAttribute::uidValidity() const
QByteArray UidValidityAttribute::type() const
{
return "uidvalidity";
static const QByteArray sType( "uidvalidity" );
return sType;
}
Akonadi::Attribute* UidValidityAttribute::clone() const
......
......@@ -92,5 +92,6 @@ int DeletedItemsAttribute::offsetCount() const
QByteArray DeletedItemsAttribute::type() const
{
return "DeletedMboxItems";
static const QByteArray sType( "DeletedMboxItems" );
return sType;
}
......@@ -29,7 +29,8 @@ NntpCollectionAttribute::NntpCollectionAttribute()
QByteArray NntpCollectionAttribute::type() const
{
return "NNTP";
static const QByteArray sType( "NNTP" );
return sType;
}
NntpCollectionAttribute * NntpCollectionAttribute::clone() const
......
......@@ -46,7 +46,8 @@ QMap<QByteArray, QByteArray> CollectionAnnotationsAttribute::annotations() const
QByteArray CollectionAnnotationsAttribute::type() const
{
return "collectionannotations";
static const QByteArray sType( "collectionannotations" );
return sType;
}
Akonadi::Attribute* CollectionAnnotationsAttribute::clone() const
......
......@@ -41,7 +41,8 @@ QList<QByteArray> CollectionFlagsAttribute::flags() const
QByteArray CollectionFlagsAttribute::type() const
{
return "collectionflags";
static const QByteArray sType( "collectionflags" );
return sType;
}
Akonadi::Attribute* CollectionFlagsAttribute::clone() const
......
......@@ -81,7 +81,8 @@ QString FileStore::EntityCompactChangeAttribute::remoteRevision() const
QByteArray FileStore::EntityCompactChangeAttribute::type() const
{
return "ENTITYCOMPACTCHANGE";
static const QByteArray sType( "ENTITYCOMPACTCHANGE" );
return sType;
}
FileStore::EntityCompactChangeAttribute* FileStore::EntityCompactChangeAttribute::clone() const
......
......@@ -51,7 +51,8 @@ QMap<QByteArray, KIMAP::Acl::Rights> ImapAclAttribute::oldRights() const
QByteArray ImapAclAttribute::type() const
{
return "imapacl";
static const QByteArray sType( "imapacl" );
return sType;
}
Akonadi::Attribute* ImapAclAttribute::clone() const
......
......@@ -69,7 +69,8 @@ QList< QMap<QByteArray, qint64> > Akonadi::ImapQuotaAttribute::usages() const
QByteArray ImapQuotaAttribute::type() const
{
return "imapquota";
static const QByteArray sType( "imapquota" );
return sType;
}
Akonadi::Attribute* ImapQuotaAttribute::clone() const
......
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