Destroy();
}
-bool MyFrame::OnClose(void)
-{
- return TRUE;
-}
-
BEGIN_EVENT_TABLE(TestGLCanvas, wxGLCanvas)
EVT_SIZE(TestGLCanvas::OnSize)
EVT_PAINT(TestGLCanvas::OnPaint)
// OnPaint handlers must always create a wxPaintDC.
wxPaintDC dc(this);
+#ifndef __WXMOTIF__
if (!GetContext()) return;
+#endif
SetCurrent();
int width, height;
GetClientSize(& width, & height);
+#ifndef __WXMOTIF__
if (GetContext())
+#endif
{
SetCurrent();
glViewport(0, 0, width, height);