/[xmltv_parser]/trunk/xmltv_parser/main.cs
ViewVC logotype

Diff of /trunk/xmltv_parser/main.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 68 by william, Sat Mar 9 01:28:31 2013 UTC revision 69 by william, Sat Mar 9 01:36:49 2013 UTC
# Line 1  Line 1 
1  ´╗┐using System;  ´╗┐//#define DISABLE_RELEASE_MODE_KLOGLEVEL_DEBUG // when defined will turn off kLogLevel_Debug messages, in release mode
2    //#define DISABLE_DEBUG_MODE_KLOGLEVEL_VERBOSE_DEBUG // when defined will turn off kLogLevel_VerboseDebug message, in debug mode
3    using System;
4  using System.Collections.Generic;  using System.Collections.Generic;
5  using System.ComponentModel;  using System.ComponentModel;
6  using System.Data;  using System.Data;
# Line 28  namespace xmltv_parser Line 30  namespace xmltv_parser
30              gLog.CreateLog(string.Format(@"{0}\{1}", log_path, log_filename), false, LogLevel.kLogLevel_All_NoProgress, new EventHandler<LoggerOnFlushEventArgs>(Log_OnFlush));              gLog.CreateLog(string.Format(@"{0}\{1}", log_path, log_filename), false, LogLevel.kLogLevel_All_NoProgress, new EventHandler<LoggerOnFlushEventArgs>(Log_OnFlush));
31  #if DEBUG  #if DEBUG
32              LogLevel gLevel = gLog.LogLevel;              LogLevel gLevel = gLog.LogLevel;
33              gLevel |= LogLevel.kLogLevel_VerboseDebug; // this slows things down alot  #if DISABLE_DEBUG_MODE_KLOGLEVEL_VERBOSE_DEBUG
34              gLevel |= LogLevel.kLogLevel_Debug;                          gLevel &= ~LogLevel.kLogLevel_VerboseDebug;
35    #else
36                gLevel |= LogLevel.kLogLevel_VerboseDebug;
37    #endif
38                gLevel |= LogLevel.kLogLevel_Debug;
39              gLog.SetLogLevel(gLevel);              gLog.SetLogLevel(gLevel);
40  #else  #else
41              LogLevel gLevel = LogLevel.kLogLevel_Default; // set the default log level: Info, Warn, Error, Debug              LogLevel gLevel = LogLevel.kLogLevel_Default; // set the default log level: Info, Warn, Error, Debug
42              // it is OK for kLogLevel_Debug to be set in Release mode ... must of the chatty messages are from kLogLevel_VerboseDebug              // it is OK for kLogLevel_Debug to be set in Release mode ... must of the chatty messages are from kLogLevel_VerboseDebug
43    #if DISABLE_RELEASE_MODE_KLOGLEVEL_DEBUG
44                gLevel &= ~LogLevel.kLogLevel_Debug;
45    #else
46                gLevel |= LogLevel.kLogLevel_Debug;
47    #endif
48              gLevel &= ~LogLevel.kLogLevel_VerboseDebug; // ensure this is not set                          gLevel &= ~LogLevel.kLogLevel_VerboseDebug; // ensure this is not set            
49              gLog.SetLogLevel(gLevel);              gLog.SetLogLevel(gLevel);
50  #endif  #endif

Legend:
Removed from v.68  
changed lines
  Added in v.69

  ViewVC Help
Powered by ViewVC 1.1.22