]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/log.cpp
generate a text event even if SetValue() didn't really chaneg anything
[wxWidgets.git] / src / common / log.cpp
index 86a83f0954a0dbaf67ae3b0fc028eca2b30afbfa..0b2c63a2053367ced14c83a7d23f840e4c07cf9d 100644 (file)
@@ -33,6 +33,7 @@
 // wxWindows
 #ifndef WX_PRECOMP
     #include "wx/app.h"
+    #include "wx/arrstr.h"
     #include "wx/intl.h"
     #include "wx/string.h"
 #endif //WX_PRECOMP
 #include "wx/wxchar.h"
 
 // other standard headers
+#ifndef __WXWINCE__
 #include <errno.h>
+#endif
+
 #include <stdlib.h>
+
+#ifndef __WXWINCE__
 #include <time.h>
+#else
+#include "wx/msw/wince/time.h"
+#endif
 
 #if defined(__WINDOWS__)
     #include "wx/msw/private.h" // includes windows.h
@@ -178,7 +187,11 @@ void wxVLogFatalError(const wxChar *szFormat, va_list argptr)
 
     wxSafeShowMessage(_T("Fatal Error"), s_szBuf);
 
+#ifdef __WXWINCE__
+    ExitThread(3);
+#else
     abort();
+#endif
 }
 
 void wxLogFatalError(const wxChar *szFormat, ...)
@@ -454,7 +467,11 @@ void wxLog::DoLog(wxLogLevel level, const wxChar *szString, time_t t)
             DoLogString(wxString(_("Fatal error: ")) + szString, t);
             DoLogString(_("Program aborted."), t);
             Flush();
+#ifdef __WXWINCE__
+            ExitThread(3);
+#else
             abort();
+#endif
             break;
 
         case wxLOG_Error:
@@ -497,6 +514,16 @@ void wxLog::Flush()
     // nothing to do here
 }
 
+/*static*/ bool wxLog::IsAllowedTraceMask(const wxChar *mask)
+{
+    for ( wxArrayString::iterator it = ms_aTraceMasks.begin(),
+                                  en = ms_aTraceMasks.end();
+         it != en; ++it )
+        if ( *it == mask)
+            return true;
+    return false;
+}
+
 // ----------------------------------------------------------------------------
 // wxLogStderr class implementation
 // ----------------------------------------------------------------------------