|
From: <ka...@us...> - 2012-12-24 19:14:31
|
Revision: 7694
http://paintown.svn.sourceforge.net/paintown/?rev=7694&view=rev
Author: kazzmir
Date: 2012-12-24 19:14:19 +0000 (Mon, 24 Dec 2012)
Log Message:
-----------
be able to change default debug context
Modified Paths:
--------------
trunk/src/util/debug.cpp
trunk/src/util/debug.h
Modified: trunk/src/util/debug.cpp
===================================================================
--- trunk/src/util/debug.cpp 2012-12-23 08:47:19 UTC (rev 7693)
+++ trunk/src/util/debug.cpp 2012-12-24 19:14:19 UTC (rev 7694)
@@ -397,3 +397,9 @@
int Global::getDebug(){
return global_debug_level;
}
+
+std::string Global::defaultDebugContext = "default";
+
+void Global::setDefaultDebugContext(const std::string & context){
+ defaultDebugContext = context;
+}
Modified: trunk/src/util/debug.h
===================================================================
--- trunk/src/util/debug.h 2012-12-23 08:47:19 UTC (rev 7693)
+++ trunk/src/util/debug.h 2012-12-24 19:14:19 UTC (rev 7694)
@@ -101,7 +101,9 @@
void closeLog();
void setDebug(int i);
int getDebug();
-stream_type & debug(int i, const std::string & context = "paintown");
+extern std::string defaultDebugContext;
+void setDefaultDebugContext(const std::string & context);
+stream_type & debug(int i, const std::string & context = defaultDebugContext);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|