GCC warning fix.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35403 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Włodzimierz Skiba 2005-09-01 15:56:09 +00:00
parent 9f29226d68
commit e7cc2f6502

View File

@ -323,8 +323,6 @@ bool MyApp::OnInit()
if (isInteractive) if (isInteractive)
{ {
wxChar buf[100];
// Create the main frame window // Create the main frame window
frame = new MyFrame(NULL, wxID_ANY, _T("Tex2RTF"), wxDefaultPosition, wxSize(400, 300)); frame = new MyFrame(NULL, wxID_ANY, _T("Tex2RTF"), wxDefaultPosition, wxSize(400, 300));
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
@ -337,8 +335,9 @@ bool MyApp::OnInit()
if (!InputFile.empty()) if (!InputFile.empty())
{ {
wxSnprintf(buf, sizeof(buf), _T("Tex2RTF [%s]"), wxFileNameFromPath(InputFile)); wxString title;
frame->SetTitle(buf); title.Printf( _T("Tex2RTF [%s]"), wxFileNameFromPath(InputFile).c_str());
frame->SetTitle(title);
} }
// Make a menubar // Make a menubar
@ -410,24 +409,30 @@ bool MyApp::OnInit()
ReadCustomMacros((wxChar *)path.c_str()); ReadCustomMacros((wxChar *)path.c_str());
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
wxStrcpy(buf, _T("In ")); wxString inStr(_T("In "));
switch (convertMode) switch (convertMode)
{ {
case TEX_RTF: case TEX_RTF:
wxStrcat(buf, (winHelp) ? _T("WinHelp RTF") : _T("linear RTF")); if(winHelp)
break; inStr += _T("WinHelp RTF");
case TEX_HTML: else
wxStrcat(buf, _T("HTML")); inStr += _T("linear RTF");
break; break;
case TEX_XLP:
wxStrcat(buf, _T("XLP")); case TEX_HTML:
break; inStr += _T("HTML");
default: break;
wxStrcat(buf, _T("unknown"));
break; case TEX_XLP:
inStr += _T("XLP");
break;
default:
inStr += _T("unknown");
break;
} }
wxStrcat(buf, _T(" mode.")); inStr += _T(" mode.");
frame->SetStatusText(buf, 1); frame->SetStatusText(inStr, 1);
#endif // wxUSE_STATUSBAR #endif // wxUSE_STATUSBAR
frame->Show(true); frame->Show(true);
@ -443,7 +448,7 @@ bool MyApp::OnInit()
wxString path = TexPathList.FindValidPath(MacroFile); wxString path = TexPathList.FindValidPath(MacroFile);
if (!path.empty()) if (!path.empty())
ReadCustomMacros((wxChar*)path.c_str()); ReadCustomMacros((wxChar*)path.c_str());
Go(); Go();
if (runTwice) if (runTwice)