+ /* Clear internal data. Hopefully nothing relies on it at this point. */
+ _bufferModel->clear();
+ // Buffers, if deleted, send a signal that causes their removal from buffers and bufferIds.
+ // So we cannot simply go through the array in a loop (or use qDeleteAll) for deletion...
+ while(buffers.count()) { delete buffers.take(buffers.keys()[0]); }
+ Q_ASSERT(!buffers.count()); // should be empty now!
+ Q_ASSERT(!bufferIds.count());
+ coreConnectionInfo.clear();
+ sessionData.clear();
+ nicks.clear();
+ netConnected.clear();
+ netsAwaitingInit.clear();
+ ownNick.clear();
+ layoutQueue.clear();
+ layoutTimer->stop();