#include "wx/sizer.h"
#include "wx/statbmp.h"
#include "wx/settings.h"
+ #include "wx/wxcrtvararg.h"
#endif // WX_PRECOMP
#if wxUSE_LOGGUI || wxUSE_LOGWINDOW
// accepts an additional argument which tells to which frame the output should
// be directed
-void wxVLogStatus(wxFrame *pFrame, const wxChar *szFormat, va_list argptr)
+void wxVLogStatus(wxFrame *pFrame, const wxString& format, va_list argptr)
{
wxString msg;
wxLog *pLog = wxLog::GetActiveTarget();
if ( pLog != NULL ) {
- msg.PrintfV(szFormat, argptr);
+ msg.PrintfV(format, argptr);
wxASSERT( gs_pFrame == NULL ); // should be reset!
gs_pFrame = pFrame;
}
}
-void wxDoLogStatus(wxFrame *pFrame, const wxChar *szFormat, ...)
+#if !wxUSE_UTF8_LOCALE_ONLY
+void wxDoLogStatusWchar(wxFrame *pFrame, const wxChar *format, ...)
{
va_list argptr;
- va_start(argptr, szFormat);
- wxVLogStatus(pFrame, szFormat, argptr);
+ va_start(argptr, format);
+ wxVLogStatus(pFrame, format, argptr);
va_end(argptr);
}
+#endif // !wxUSE_UTF8_LOCALE_ONLY
+
+#if wxUSE_UNICODE_UTF8
+void wxDoLogStatusUtf8(wxFrame *pFrame, const char *format, ...)
+{
+ va_list argptr;
+ va_start(argptr, format);
+ wxVLogStatus(pFrame, format, argptr);
+ va_end(argptr);
+}
+#endif // wxUSE_UNICODE_UTF8
// ----------------------------------------------------------------------------
// wxLogGui implementation (FIXME MT-unsafe)
wxLogError(_("Can't save log contents to file."));
}
else {
- wxLogStatus(this, _("Log saved to the file '%s'."), filename.c_str());
+ wxLogStatus((wxFrame*)this, _("Log saved to the file '%s'."), filename.c_str());
}
#endif
}