A few Unicode fixes.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@6938 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -668,7 +668,7 @@ void wxPrintData::ConvertFromNative()
|
|||||||
// Not sure if we should check for this mismatch
|
// Not sure if we should check for this mismatch
|
||||||
// wxASSERT_MSG( (m_printerName == "" || (devName == m_printerName)), "Printer name obtained from DEVMODE and DEVNAMES were different!");
|
// wxASSERT_MSG( (m_printerName == "" || (devName == m_printerName)), "Printer name obtained from DEVMODE and DEVNAMES were different!");
|
||||||
|
|
||||||
if (printerName != "")
|
if (printerName != wxT(""))
|
||||||
m_printerName = printerName;
|
m_printerName = printerName;
|
||||||
|
|
||||||
GlobalUnlock(hDevNames);
|
GlobalUnlock(hDevNames);
|
||||||
|
@@ -42,7 +42,6 @@
|
|||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include <ctype.h> // for isalnum()
|
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// global and class static variables
|
// global and class static variables
|
||||||
@@ -292,13 +291,13 @@ wxString wxExpandEnvVars(const wxString& str)
|
|||||||
for ( size_t n = 0; n < str.Len(); n++ ) {
|
for ( size_t n = 0; n < str.Len(); n++ ) {
|
||||||
switch ( str[n] ) {
|
switch ( str[n] ) {
|
||||||
#ifdef __WXMSW__
|
#ifdef __WXMSW__
|
||||||
case '%':
|
case wxT('%'):
|
||||||
#endif //WINDOWS
|
#endif //WINDOWS
|
||||||
case '$':
|
case wxT('$'):
|
||||||
{
|
{
|
||||||
Bracket bracket;
|
Bracket bracket;
|
||||||
#ifdef __WXMSW__
|
#ifdef __WXMSW__
|
||||||
if ( str[n] == '%' )
|
if ( str[n] == wxT('%') )
|
||||||
bracket = Bracket_Windows;
|
bracket = Bracket_Windows;
|
||||||
else
|
else
|
||||||
#endif //WINDOWS
|
#endif //WINDOWS
|
||||||
@@ -307,12 +306,12 @@ wxString wxExpandEnvVars(const wxString& str)
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
switch ( str[n + 1] ) {
|
switch ( str[n + 1] ) {
|
||||||
case '(':
|
case wxT('('):
|
||||||
bracket = Bracket_Normal;
|
bracket = Bracket_Normal;
|
||||||
n++; // skip the bracket
|
n++; // skip the bracket
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case '{':
|
case wxT('{'):
|
||||||
bracket = Bracket_Curly;
|
bracket = Bracket_Curly;
|
||||||
n++; // skip the bracket
|
n++; // skip the bracket
|
||||||
break;
|
break;
|
||||||
@@ -324,7 +323,7 @@ wxString wxExpandEnvVars(const wxString& str)
|
|||||||
|
|
||||||
m = n + 1;
|
m = n + 1;
|
||||||
|
|
||||||
while ( m < str.Len() && (isalnum(str[m]) || str[m] == '_') )
|
while ( m < str.Len() && (wxIsalnum(str[m]) || str[m] == wxT('_')) )
|
||||||
m++;
|
m++;
|
||||||
|
|
||||||
wxString strVarName(str.c_str() + n + 1, m - n - 1);
|
wxString strVarName(str.c_str() + n + 1, m - n - 1);
|
||||||
@@ -363,7 +362,7 @@ wxString wxExpandEnvVars(const wxString& str)
|
|||||||
|
|
||||||
case '\\':
|
case '\\':
|
||||||
// backslash can be used to suppress special meaning of % and $
|
// backslash can be used to suppress special meaning of % and $
|
||||||
if ( n != str.Len() && (str[n + 1] == '%' || str[n + 1] == '$') ) {
|
if ( n != str.Len() && (str[n + 1] == wxT('%') || str[n + 1] == wxT('$')) ) {
|
||||||
strResult += str[++n];
|
strResult += str[++n];
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@@ -165,7 +165,7 @@ bool wxMemoryFSHandler::CheckHash(const wxString& filename)
|
|||||||
{
|
{
|
||||||
wxString s;
|
wxString s;
|
||||||
s.Printf(_("Failed to store image '%s' to memory VFS!"), filename.c_str());
|
s.Printf(_("Failed to store image '%s' to memory VFS!"), filename.c_str());
|
||||||
printf("'%s'\n", s.c_str());
|
wxPrintf(wxT("'%s'\n"), s.c_str());
|
||||||
wxLogError(s);
|
wxLogError(s);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -292,7 +292,7 @@ static wxString GetFullSearchPath(const wxChar *lang)
|
|||||||
|
|
||||||
// LC_PATH is a standard env var containing the search path for the .mo
|
// LC_PATH is a standard env var containing the search path for the .mo
|
||||||
// files
|
// files
|
||||||
const wxChar *pszLcPath = wxGetenv("LC_PATH");
|
const wxChar *pszLcPath = wxGetenv(wxT("LC_PATH"));
|
||||||
if ( pszLcPath != NULL )
|
if ( pszLcPath != NULL )
|
||||||
searchPath << GetAllMsgCatalogSubdirs(pszLcPath, lang);
|
searchPath << GetAllMsgCatalogSubdirs(pszLcPath, lang);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user