added null pointer check in DoGetSize functions; else programs crash when resizing list heads

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@7902 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Unknown (NI)
2000-07-30 08:42:13 +00:00
parent 0bc6abf126
commit f6fb552e5d

View File

@@ -1199,7 +1199,7 @@ void wxWindow::DoGetSize(int *x, int *y) const
Widget widget = (Widget) GetTopWidget();
Dimension xx, yy;
XtVaGetValues(widget, XmNwidth, &xx, XmNheight, &yy, NULL);
*x = xx; *y = yy;
if(x) *x = xx; if(y) *y = yy;
}
void wxWindow::DoGetPosition(int *x, int *y) const
@@ -1222,7 +1222,7 @@ void wxWindow::DoGetPosition(int *x, int *y) const
yy -= pt.y;
}
*x = xx; *y = yy;
if(x) *x = xx; if(y) *y = yy;
}
void wxWindow::DoScreenToClient(int *x, int *y) const
@@ -1258,7 +1258,7 @@ void wxWindow::DoGetClientSize(int *x, int *y) const
Widget widget = (Widget) GetClientWidget();
Dimension xx, yy;
XtVaGetValues(widget, XmNwidth, &xx, XmNheight, &yy, NULL);
*x = xx; *y = yy;
if(x) *x = xx; if(y) *y = yy;
}
void wxWindow::DoSetSize(int x, int y, int width, int height, int sizeFlags)