]> git.saurik.com Git - wxWidgets.git/commitdiff
show the app name in the title of wxMsgOut message boxes
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 7 Sep 2002 20:25:43 +0000 (20:25 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 7 Sep 2002 20:25:43 +0000 (20:25 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@17056 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/msgout.cpp

index 1ac9f944f84528eb90b1eafe3eec133dfc310a95..0d03ccc7c12451b25c4c39dabf118b2b3cff87d8 100755 (executable)
@@ -97,10 +97,16 @@ void wxMessageOutputMessageBox::Printf(const wxChar* format, ...)
     out.PrintfV(format, args);
     va_end(args);
 
     out.PrintfV(format, args);
     va_end(args);
 
+    // the native MSW msg box understands the TABs, others don't
 #ifndef __WXMSW__
 #ifndef __WXMSW__
-    out.Replace(wxT("\t"),wxT("        "));
+    out.Replace(wxT("\t"), wxT("        "));
 #endif
 #endif
-    ::wxMessageBox(out);
+
+    wxString title;
+    if ( wxTheApp )
+        title.Printf(_("%s message"), wxTheApp->GetAppName().c_str());
+
+    ::wxMessageBox(out, title);
 }
 
 #endif // wxUSE_GUI
 }
 
 #endif // wxUSE_GUI
@@ -119,7 +125,7 @@ void wxMessageOutputLog::Printf(const wxChar* format, ...)
     out.PrintfV(format, args);
     va_end(args);
 
     out.PrintfV(format, args);
     va_end(args);
 
-    out.Replace(wxT("\t"),wxT("        "));
+    out.Replace(wxT("\t"), wxT("        "));
 
     ::wxLogMessage(wxT("%s"), out.c_str());
 }
 
     ::wxLogMessage(wxT("%s"), out.c_str());
 }