More Unicode stuff. Implemented wxFprintf.

Some printfs changed to wxPrintf, fprintf to wxFprintf, as well as the
usual char->wxChar and _T().


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2133 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Ove Kaaven
1999-04-13 10:34:24 +00:00
parent 6d9bd0682c
commit 84fff0b395
8 changed files with 76 additions and 52 deletions

View File

@@ -319,7 +319,7 @@ wxTime wxTime::Min(const wxTime& t) const
}
#ifndef __SALFORDC__
wxTime::operator char *(void)
wxTime::operator wxChar *(void)
{
return FormatTime();
}
@@ -332,8 +332,8 @@ void wxTime::SetFormat(const wxTime::tFormat lFormat,
wxTime::Precision = lPrecision;
}
char *wxTime::FormatTime() const {
static char timeBuf[30];
wxChar *wxTime::FormatTime() const {
static wxChar timeBuf[30];
unsigned hh(GetHour());
switch (Format) {
@@ -346,18 +346,18 @@ char *wxTime::FormatTime() const {
switch (Precision) {
case wxStdMinSec:
sprintf(timeBuf,"%2d:%02d:%02d",hh,GetMinute(),GetSecond());
wxSprintf(timeBuf,_T("%2d:%02d:%02d"),hh,GetMinute(),GetSecond());
break;
case wxStdMin:
sprintf(timeBuf,"%2d:%02d",hh,GetMinute());
wxSprintf(timeBuf,_T("%2d:%02d"),hh,GetMinute());
break;
}
if (Format == wx12h)
if (GetHour() <= 12)
strcat(timeBuf,_("am"));
wxStrcat(timeBuf,_("am"));
else
strcat(timeBuf,_("pm"));
wxStrcat(timeBuf,_("pm"));
return timeBuf;
}