Applied patch #561454, testing for scrollbar

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15705 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2002-05-29 08:31:59 +00:00
parent feaca34f34
commit c4cb3d0f0c

View File

@@ -817,8 +817,9 @@ int wxWindow::GetScrollRange(int orient) const
Widget scrollBar = (Widget)GetScrollbar((wxOrientation)orient);
wxCHECK_MSG( scrollBar, 0, "no such scrollbar" );
int range;
XtVaGetValues(scrollBar, XmNmaximum, &range, NULL);
int range = 0;
if (scrollBar)
XtVaGetValues(scrollBar, XmNmaximum, &range, NULL);
return range;
}