From: Julian Smart Date: Sun, 24 Aug 2003 14:30:23 +0000 (+0000) Subject: Eliminated bizarre VC++ internal compiler errors, perhaps related to X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/7d2d5d81951888e76f93b33aca9899a9c480022b?ds=inline Eliminated bizarre VC++ internal compiler errors, perhaps related to enabling C++ RTTI git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23168 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/statbar.cpp b/src/common/statbar.cpp index 238802c0c2..984a9e1278 100644 --- a/src/common/statbar.cpp +++ b/src/common/statbar.cpp @@ -250,7 +250,11 @@ void wxStatusBarBase::FreeStacks() void wxStatusBarBase::PushStatusText(const wxString& text, int number) { wxListString* st = GetOrCreateStatusStack(number); - st->Insert(new wxString(GetStatusText(number))); + // This long-winded way around avoids an internal compiler error + // in VC++ 6 with RTTI enabled + wxString tmp1(GetStatusText(number)); + wxString* tmp = new wxString(tmp1); + st->Insert(tmp); SetStatusText(text, number); } diff --git a/src/msw/statbr95.cpp b/src/msw/statbr95.cpp index 058f3b6f35..3b203df0b0 100644 --- a/src/msw/statbr95.cpp +++ b/src/msw/statbr95.cpp @@ -250,7 +250,7 @@ void wxStatusBar95::DoMoveWindow(int x, int y, int width, int height) // omitted because for normal status bars (positioned along the bottom // edge) the position is already set correctly, but if the user wants to // position them in some exotic location, this is really needed - wxWindow::DoMoveWindow(x, y, width, height); + wxWindowMSW::DoMoveWindow(x, y, width, height); // adjust fields widths to the new size SetFieldsWidth();