]> git.saurik.com Git - wxWidgets.git/commitdiff
Unicode compilation fixes
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 9 Dec 2006 15:58:32 +0000 (15:58 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 9 Dec 2006 15:58:32 +0000 (15:58 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43876 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

tests/filename/filenametest.cpp
tests/strings/vsnprintf.cpp

index 889b28262c6e7a1d66a5ce601df9d5bfa948768b..992a05a8bfa42fe9a28809832f8325d49d3371a4 100644 (file)
@@ -149,7 +149,7 @@ void FileNameTestCase::TestConstruction()
         // if the test is run from root directory or its direct subdirectory
         CPPUNIT_ASSERT_MESSAGE
         (
         // if the test is run from root directory or its direct subdirectory
         CPPUNIT_ASSERT_MESSAGE
         (
-            wxString::Format("Normalize(%s) failed", fni.fullname).c_str(),
+            (const char *)wxString::Format(_T("Normalize(%s) failed"), fni.fullname).mb_str(),
             fn.Normalize(wxPATH_NORM_ALL, _T("/foo/bar/baz"), fni.format)
         );
 
             fn.Normalize(wxPATH_NORM_ALL, _T("/foo/bar/baz"), fni.format)
         );
 
@@ -274,7 +274,7 @@ void FileNameTestCase::TestNormalize()
         // be sure this normalization does not fail
         CPPUNIT_ASSERT_MESSAGE
         (
         // be sure this normalization does not fail
         CPPUNIT_ASSERT_MESSAGE
         (
-            wxString::Format("Normalize(%s) failed", tests[i].original).c_str(),
+            (const char *)wxString::Format(_T("Normalize(%s) failed"), tests[i].original).mb_str(),
             fn.Normalize(tests[i].flags, cwd, wxPATH_UNIX)
         );
 
             fn.Normalize(tests[i].flags, cwd, wxPATH_UNIX)
         );
 
index 640cc307a64714e05e7db3ff9b714c1ede117b18..fc77afe626e04f7501c73aa677fc463c27398a4d 100644 (file)
@@ -253,7 +253,7 @@ void VsnprintfTestCase::S()
     CMP3("abcde", "%.5s", wxT("abcdefghi"));
 
     // do the same tests but with Unicode characters:
     CMP3("abcde", "%.5s", wxT("abcdefghi"));
 
     // do the same tests but with Unicode characters:
-#if wxUSE_UNICODE
+#if wxUSE_UNICODE && !defined(__VISUALC__) // FIXME: this doesn't compile with VC7
     #define ALPHA     "\x3B1"
     #define BETA      "\x3B2"
     #define GAMMA     "\x3B3"
     #define ALPHA     "\x3B1"
     #define BETA      "\x3B2"
     #define GAMMA     "\x3B3"