since seezer was too slow: fixing double click buffer switches in the chatmonitor
[quassel.git] / src / client / clientbufferviewconfig.cpp
index 86fbfd9..1e7f816 100644 (file)
 
 #include "clientbufferviewconfig.h"
 
+INIT_SYNCABLE_OBJECT(ClientBufferViewConfig)
 ClientBufferViewConfig::ClientBufferViewConfig(int bufferViewId, QObject *parent)
   : BufferViewConfig(bufferViewId, parent),
     _locked(false)
 {
+  connect(this, SIGNAL(initDone()), this, SLOT(ensureDecoration()));
+}
+
+// currently we don't have a possibility to configure disableDecoration
+// if we have an old config this value can be true which is... bad.
+// so we upgrade the core stored bufferViewConfig.
+// This can be removed with the next release
+void ClientBufferViewConfig::ensureDecoration() {
+  if(!disableDecoration())
+    return;
+  setDisableDecoration(false);
+  requestUpdate(toVariantMap());
 }