Put m_statusText.SetCount(number) before wxStatusBarBase::SetFieldsCount(number, widths) to avoid assert (a refresh is done in SetFieldsCount which

access the m_statusText array before the size is set).
XQueryTree usage improved.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14128 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2002-02-11 13:11:28 +00:00
parent 3603a8ffbd
commit ca7497c2a2
3 changed files with 5 additions and 5 deletions

View File

@@ -186,9 +186,8 @@ wxString wxStatusBarUniv::GetStatusText(int number) const
void wxStatusBarUniv::SetFieldsCount(int number, const int *widths) void wxStatusBarUniv::SetFieldsCount(int number, const int *widths)
{ {
wxStatusBarBase::SetFieldsCount(number, widths);
m_statusText.SetCount(number); m_statusText.SetCount(number);
wxStatusBarBase::SetFieldsCount(number, widths);
m_widthsAbs.Empty(); m_widthsAbs.Empty();
} }

View File

@@ -598,6 +598,10 @@ void wxApp::DeletePendingObjects()
// Create an application context // Create an application context
bool wxApp::OnInitGui() bool wxApp::OnInitGui()
{ {
// Eventually this line will be removed, but for
// now we don't want to try popping up a dialog
// for error messages.
delete wxLog::SetActiveTarget(new wxLogStderr);
if (!wxAppBase::OnInitGui()) if (!wxAppBase::OnInitGui())
return FALSE; return FALSE;

View File

@@ -156,9 +156,6 @@ wxTopLevelWindowX11::~wxTopLevelWindowX11()
bool wxTopLevelWindowX11::Show(bool show) bool wxTopLevelWindowX11::Show(bool show)
{ {
if ( !wxWindowBase::Show(show) )
return FALSE;
return wxWindowX11::Show(show); return wxWindowX11::Show(show);
} }