Update of /cvsroot/wxlua/wxLua/modules/luamodule/src
In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv5429/wxLua/modules/luamodule/src
Modified Files:
luamodule.cpp
Log Message:
wxPrintf errors if we cannot initialize wxWidgets from a DLL
Index: luamodule.cpp
===================================================================
RCS file: /cvsroot/wxlua/wxLua/modules/luamodule/src/luamodule.cpp,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** luamodule.cpp 4 Sep 2006 18:29:59 -0000 1.4
--- luamodule.cpp 4 May 2007 16:12:24 -0000 1.5
***************
*** 34,40 ****
// Override the base class virtual functions
! bool OnInit();
! int OnExit();
! int MainLoop();
void OnLua( wxLuaEvent &event );
--- 34,40 ----
// Override the base class virtual functions
! virtual bool OnInit();
! virtual int OnExit();
! virtual int MainLoop();
void OnLua( wxLuaEvent &event );
***************
*** 107,114 ****
if (!s_wxlState.Ok())
{
! int argc = 0;
! wxChar **argv = NULL;
! wxEntryStart(argc, argv);
! wxTheApp->CallOnInit();
wxTheApp->SetExitOnFrameDelete(true);
--- 107,123 ----
if (!s_wxlState.Ok())
{
! int argc = 0;
! wxChar **argv = NULL;
!
! if (!wxEntryStart(argc, argv))
! {
! wxPrintf(wxT("Error calling wxEntryStart(argc, argv), aborting.\n"));
! return 0;
! }
! if (!wxTheApp || !wxTheApp->CallOnInit())
! {
! wxPrintf(wxT("Error calling wxTheApp->CallOnInit(), aborting.\n"));
! return 0;
! }
wxTheApp->SetExitOnFrameDelete(true);
|