From 7d03876a3e11aedff0201a8330bfdb2b5523fc5e Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Wed, 29 Jan 2014 19:22:03 +0000 Subject: Added LOGREPLACELINE for line replacement --- src/MCLogger.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/MCLogger.h') diff --git a/src/MCLogger.h b/src/MCLogger.h index c949a4cdf..7bcc195dd 100644 --- a/src/MCLogger.h +++ b/src/MCLogger.h @@ -21,7 +21,7 @@ public: // tolua_export ~cMCLogger(); // tolua_export - void Log(const char* a_Format, va_list a_ArgList); + void Log(const char* a_Format, va_list a_ArgList, bool a_ShouldReplaceLine = false); void Info(const char* a_Format, va_list a_ArgList); void Warn(const char* a_Format, va_list a_ArgList); void Error(const char* a_Format, va_list a_ArgList); @@ -51,12 +51,17 @@ private: /// Common initialization for all constructors, creates a logfile with the specified name and assigns s_MCLogger to this void InitLog(const AString & a_FileName); + + /** Flag to show whether a 'replace line' log command has been issued + Used to decide when to put a newline */ + bool m_BeginLineUpdate = false; }; // tolua_export +extern void LOGREPLACELINE(const char* a_Format, ...); extern void LOG(const char* a_Format, ...); extern void LOGINFO(const char* a_Format, ...); extern void LOGWARN(const char* a_Format, ...); -- cgit v1.2.3