projects
/
quassel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Breaking protocol with alpha2.... and it won't be the last one...
[quassel.git]
/
src
/
common
/
syncableobject.cpp
diff --git
a/src/common/syncableobject.cpp
b/src/common/syncableobject.cpp
index
668f61c
..
ee871b8
100644
(file)
--- a/
src/common/syncableobject.cpp
+++ b/
src/common/syncableobject.cpp
@@
-96,3
+96,11
@@
bool SyncableObject::setInitValue(const QString &property, const QVariant &value
QGenericArgument param(value.typeName(), value.constData());
return QMetaObject::invokeMethod(this, handlername.toAscii(), param);
}
QGenericArgument param(value.typeName(), value.constData());
return QMetaObject::invokeMethod(this, handlername.toAscii(), param);
}
+
+void SyncableObject::renameObject(const QString &newName) {
+ const QString oldName = objectName();
+ if(oldName != newName) {
+ setObjectName(newName);
+ emit objectRenamed(newName, oldName);
+ }
+}