summaryrefslogtreecommitdiff
path: root/src/log.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/log.cpp')
-rw-r--r--src/log.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/log.cpp b/src/log.cpp
index 63a34776..96630a96 100644
--- a/src/log.cpp
+++ b/src/log.cpp
@@ -34,8 +34,11 @@
#include "log.h"
+#include "gui/chat.h"
+
Logger::Logger():
- mLogToStandardOut(false)
+ mLogToStandardOut(false),
+ mChatWindow(NULL)
{
}
@@ -100,6 +103,11 @@ void Logger::log(const char *log_text, ...)
std::cout << timeStr.str() << buf << std::endl;
}
+ if (mChatWindow)
+ {
+ mChatWindow->chatLog(buf, BY_LOGGER);
+ }
+
// Delete temporary buffer
delete[] buf;
}