Unicodified wxSplitPath
authorOve Kaaven <ovek@arcticnet.no>
Fri, 16 Apr 1999 23:06:39 +0000 (23:06 +0000)
committerOve Kaaven <ovek@arcticnet.no>
Fri, 16 Apr 1999 23:06:39 +0000 (23:06 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2211 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/config.cpp

index b9aefd7202eff8388e33b7fb126c408c3496cbbc..401d25f2365679007b85bec5a6b8c39ac9b1103e 100644 (file)
@@ -365,18 +365,18 @@ wxString wxExpandEnvVars(const wxString& str)
 }
 
 // this function is used to properly interpret '..' in path
-void wxSplitPath(wxArrayString& aParts, const char *sz)
+void wxSplitPath(wxArrayString& aParts, const wxChar *sz)
 {
   aParts.Empty();
 
   wxString strCurrent;
-  const char *pc = sz;
+  const wxChar *pc = sz;
   for ( ;; ) {
-    if ( *pc == '\0' || *pc == wxCONFIG_PATH_SEPARATOR ) {
-      if ( strCurrent == "." ) {
+    if ( *pc == _T('\0') || *pc == wxCONFIG_PATH_SEPARATOR ) {
+      if ( strCurrent == _T(".") ) {
         // ignore
       }
-      else if ( strCurrent == ".." ) {
+      else if ( strCurrent == _T("..") ) {
         // go up one level
         if ( aParts.IsEmpty() )
           wxLogWarning(_("'%s' has extra '..', ignored."), sz);
@@ -392,7 +392,7 @@ void wxSplitPath(wxArrayString& aParts, const char *sz)
       //else:
         // could log an error here, but we prefer to ignore extra '/'
 
-      if ( *pc == '\0' )
+      if ( *pc == _T('\0') )
         return;
     }
     else