+
+ return true;
+}
+
+#endif // NEED_UNICODE_CHECK
+
+// ----------------------------------------------------------------------------
+// Windows-specific wxEntry
+// ----------------------------------------------------------------------------
+
+// helper function used to clean up in wxEntry() just below
+//
+// notice that argv elements are supposed to be allocated using malloc() while
+// argv array itself is allocated with new
+static void wxFreeArgs(int argc, wxChar **argv)
+{
+ for ( int i = 0; i < argc; i++ )
+ {
+ free(argv[i]);
+ }
+
+ delete [] argv;
+}
+
+WXDLLEXPORT int wxEntry(HINSTANCE hInstance,
+ HINSTANCE WXUNUSED(hPrevInstance),
+ wxCmdLineArgType WXUNUSED(pCmdLine),
+ int nCmdShow)
+{
+ // the first thing to do is to check if we're trying to run an Unicode
+ // program under Win9x w/o MSLU emulation layer - if so, abort right now
+ // as it has no chance to work and has all chances to crash
+#ifdef NEED_UNICODE_CHECK
+ if ( !wxIsUnicodeAvailable() )
+ return -1;
+#endif // NEED_UNICODE_CHECK