Define wxEntry() with WinMain-compatible signature for all Windows ports.
Make wxEntry(HINSTANCE, ...) available in wxGTK under Windows too. Refactor the headers to allow this and extract Windows-specific wxEntry() declarations in wx/msw/init.h from wx/msw/app.h for consistency with the normal wxEntry(int, char**) declared in wx/init.h. Closes #14423. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71890 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -202,7 +202,7 @@ int wxEntry(int& argc, wxChar **argv)
|
||||
|
||||
#endif // wxUSE_BASE
|
||||
|
||||
#if wxUSE_GUI && defined(__WXMSW__)
|
||||
#if wxUSE_GUI
|
||||
|
||||
namespace
|
||||
{
|
||||
@@ -358,7 +358,9 @@ wxMSWEntryCommon(HINSTANCE hInstance, int nCmdShow)
|
||||
|
||||
// remember the parameters Windows gave us
|
||||
wxSetInstance(hInstance);
|
||||
#ifdef __WXMSW__
|
||||
wxApp::m_nCmdShow = nCmdShow;
|
||||
#endif
|
||||
|
||||
// parse the command line: we can't use pCmdLine in Unicode build so it is
|
||||
// simpler to never use it at all (this also results in a more correct
|
||||
@@ -414,7 +416,7 @@ WXDLLEXPORT int wxEntry(HINSTANCE hInstance,
|
||||
return wxEntry(wxArgs.argc, wxArgs.argv);
|
||||
}
|
||||
|
||||
#endif // wxUSE_GUI && __WXMSW__
|
||||
#endif // wxUSE_GUI
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// global HINSTANCE
|
||||
|
Reference in New Issue
Block a user