// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-#ifdef __GNUG__
-#pragma implementation
-#pragma interface
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
// `Main program' equivalent, creating windows and returning main app frame
bool MyApp::OnInit()
{
+ if ( !wxApp::OnInit() )
+ return false;
+
Args(argc, argv);
// Create the main frame window
frame = new MyFrame(NULL, wxT("wxWidgets OpenGL Isosurf Sample"),
wxDefaultPosition, wxDefaultSize);
- // Give it an icon
- frame->SetIcon(wxIcon(_T("mondrian")));
-
// Make a menubar
wxMenu *fileMenu = new wxMenu;
int gl_attrib[20] = { WX_GL_RGBA, WX_GL_MIN_RED, 1, WX_GL_MIN_GREEN, 1,
WX_GL_MIN_BLUE, 1, WX_GL_DEPTH_SIZE, 1,
WX_GL_DOUBLEBUFFER,
-# ifdef __WXMAC__
+# if defined(__WXMAC__) || defined(__WXCOCOA__)
GL_NONE };
# else
None };
: wxFrame(frame, wxID_ANY, title, pos, size, style)
{
m_canvas = NULL;
- SetIcon(wxIcon(sample_xpm));
+ SetIcon(wxICON(sample));
}
MyFrame::~MyFrame()