]> git.saurik.com Git - wxWidgets.git/commitdiff
Corrected wxFormatConverter for strings which need
authorRobert Roebling <robert@roebling.de>
Mon, 26 Aug 2002 20:58:56 +0000 (20:58 +0000)
committerRobert Roebling <robert@roebling.de>
Mon, 26 Aug 2002 20:58:56 +0000 (20:58 +0000)
   not get converted.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16794 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/wxchar.cpp

index a161262499f3515c3dd57090fd3c4398651fffa0..4da43cbd344c4b4aedef911b68ce41ef07990fb0 100644 (file)
@@ -566,7 +566,7 @@ class wxFormatConverter
 public:
     wxFormatConverter(const wxChar *format);
 
-    operator const wxChar *() const { return m_fmt.c_str(); }
+    operator const wxChar *() const { return m_nCopied ? m_fmtOrig : m_fmt.c_str(); }
 
 private:
     // copy another character to the translated format: this function does the
@@ -777,7 +777,7 @@ int wxPrintf( const wxChar *format, ... ) ATTRIBUTE_PRINTF_2
 {
     va_list argptr;
     va_start(argptr, format);
-
+    
     int ret = vwprintf( wxFormatConverter(format), argptr );
 
     va_end(argptr);