]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/cmdline.cpp
1. derive wxGTK wxRadioBox from wxRadioBoxBase now, as in all other ports
[wxWidgets.git] / src / common / cmdline.cpp
index 4115c72fd3b15c19d04f40fac290564476050b0d..12012e680708bd2092ffac0a1850254578bfb95d 100644 (file)
@@ -120,7 +120,7 @@ struct wxCmdLineOption
     void SetStrVal(const wxString& val)
         { Check(wxCMD_LINE_VAL_STRING); m_strVal = val; m_hasVal = true; }
 #if wxUSE_DATETIME
-    void SetDateVal(const wxDateTime val)
+    void SetDateVal(const wxDateTime& val)
         { Check(wxCMD_LINE_VAL_DATE); m_dateVal = val; m_hasVal = true; }
 #endif // wxUSE_DATETIME
 
@@ -241,7 +241,10 @@ void wxCmdLineParserData::SetArguments(const wxString& cmdLine)
 {
     m_arguments.clear();
 
-    m_arguments.push_back(wxTheApp ? wxTheApp->argv[0] : _T(""));
+    if(wxTheApp && wxTheApp->argc > 0)
+        m_arguments.push_back(wxTheApp->argv[0]);
+    else
+        m_arguments.push_back(wxEmptyString);
 
     wxArrayString args = wxCmdLineParser::ConvertStringToArgs(cmdLine);
 
@@ -1220,4 +1223,3 @@ wxArrayString wxCmdLineParser::ConvertStringToArgs(const wxChar *p)
 
     return args;
 }
-