better handling of log messages (internal stuff only)
[quassel.git] / src / client / client.h
index b8faf9f..9f881d1 100644 (file)
@@ -112,6 +112,9 @@ public:
   static void setBufferLastSeenMsg(BufferId id, const MsgId &msgId); // this is synced to core and other clients
   static void removeBuffer(BufferId id);
 
+  static void logMessage(QtMsgType type, const char *msg);
+  static inline const QString &debugLog() { return instance()->_debugLogBuffer; }
+
 signals:
   void sendInput(BufferInfo, QString message);
   void requestNetworkStates();
@@ -149,6 +152,8 @@ signals:
 
   void newClientSyncer(ClientSyncer *);
 
+  void logUpdated(const QString &msg);
+
 public slots:
   //void selectBuffer(Buffer *);
 
@@ -207,6 +212,9 @@ private:
 
   static AccountId _currentCoreAccount;
 
+  QString _debugLogBuffer;
+  QTextStream _debugLog;
+
   friend class ClientSyncer;
 };