+ LogLastRepeatIfNeeded();
+}
+
+/*static*/ bool wxLog::IsAllowedTraceMask(const wxString& mask)
+{
+ wxCRIT_SECT_LOCKER(lock, GetTraceMaskCS());
+
+ for ( wxArrayString::iterator it = ms_aTraceMasks.begin(),
+ en = ms_aTraceMasks.end();
+ it != en; ++it )
+ {
+ if ( *it == mask)
+ return true;
+ }
+
+ return false;
+}
+
+// ----------------------------------------------------------------------------
+// wxLogBuffer implementation
+// ----------------------------------------------------------------------------
+
+void wxLogBuffer::Flush()
+{
+ if ( !m_str.empty() )
+ {
+ wxMessageOutputBest out;
+ out.Printf(wxS("%s"), m_str.c_str());
+ m_str.clear();
+ }
+}
+
+void wxLogBuffer::DoLog(wxLogLevel level, const wxString& szString, time_t t)
+{
+ switch ( level )
+ {
+ case wxLOG_Trace:
+ case wxLOG_Debug:
+#ifdef __WXDEBUG__
+ // don't put debug messages in the buffer, we don't want to show
+ // them to the user in a msg box, log them immediately
+ {
+ wxString str;
+ TimeStamp(&str);
+ str += szString;
+
+ wxMessageOutputDebug dbgout;
+ dbgout.Printf(wxS("%s\n"), str.c_str());
+ }
+#endif // __WXDEBUG__
+ break;
+
+ default:
+ wxLog::DoLog(level, szString, t);
+ }
+}
+
+void wxLogBuffer::DoLogString(const wxString& szString, time_t WXUNUSED(t))
+{
+ m_str << szString << wxS("\n");