X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcommon%2Fsyncableobject.cpp;h=248ccc9f45bf58fc05d81101aa6b9ab91fe13fa3;hp=426bc86cf28dd3d8f122a7e85285c6af44c5e87c;hb=335e1e55ee8df69b37b1b4d839950ced9ac08cc4;hpb=f2e4609f070221a010eef8be98524c5ce88d228b diff --git a/src/common/syncableobject.cpp b/src/common/syncableobject.cpp index 426bc86c..248ccc9f 100644 --- a/src/common/syncableobject.cpp +++ b/src/common/syncableobject.cpp @@ -37,10 +37,19 @@ SyncableObject::SyncableObject(QObject *parent) SyncableObject::SyncableObject(const SyncableObject &other, QObject *parent) : QObject(parent), _initialized(other._initialized), - _allowClientUpdates(false) + _allowClientUpdates(other._allowClientUpdates) { } +SyncableObject &SyncableObject::operator=(const SyncableObject &other) { + if(this == &other) + return *this; + + _initialized = other._initialized; + _allowClientUpdates = other._allowClientUpdates; + return *this; +} + bool SyncableObject::isInitialized() const { return _initialized; } @@ -101,7 +110,7 @@ void SyncableObject::fromVariantMap(const QVariantMap &properties) { iterator++; continue; } - + int propertyIndex = meta->indexOfProperty(propName.toAscii()); if(propertyIndex == -1 || !meta->property(propertyIndex).isWritable())