Change wxLongLongFmtSpec to be a non-wide string.
As with other ANSI/Unicode unification changes, we choose to preserve compatibility with the existing code using wxLongLongFmtSpec in ANSI build and require people using it in Unicode build to change their code. Closes #11372. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62562 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
7b611a3ae9
commit
651548666a
@ -283,6 +283,11 @@ Changes in behaviour which may result in compilation errors
|
||||
presence of an element in the list only. If you used it as Find(), simple do
|
||||
use Find() instead.
|
||||
|
||||
- wxLongLongFmtSpec is now a normal and not wide string so you will need to
|
||||
change expressions of the form wxT("%") wxLongLongFmtSpec wxT("x") to
|
||||
just "%" wxLongLongFmtSpec "x", i.e. simply remove wxT() from the strings you
|
||||
concatenate with it.
|
||||
|
||||
|
||||
Deprecated methods and their replacements
|
||||
-----------------------------------------
|
||||
|
@ -978,28 +978,28 @@ typedef wxUint32 wxDword;
|
||||
#if (defined(__VISUALC__) && defined(__WIN32__))
|
||||
#define wxLongLong_t __int64
|
||||
#define wxLongLongSuffix i64
|
||||
#define wxLongLongFmtSpec wxT("I64")
|
||||
#define wxLongLongFmtSpec "I64"
|
||||
#elif defined(__BORLANDC__) && defined(__WIN32__) && (__BORLANDC__ >= 0x520)
|
||||
#define wxLongLong_t __int64
|
||||
#define wxLongLongSuffix i64
|
||||
#define wxLongLongFmtSpec wxT("L")
|
||||
#define wxLongLongFmtSpec "L"
|
||||
#elif (defined(__WATCOMC__) && (defined(__WIN32__) || defined(__DOS__) || defined(__OS2__)))
|
||||
#define wxLongLong_t __int64
|
||||
#define wxLongLongSuffix i64
|
||||
#define wxLongLongFmtSpec wxT("L")
|
||||
#define wxLongLongFmtSpec "L"
|
||||
#elif defined(__DIGITALMARS__)
|
||||
#define wxLongLong_t __int64
|
||||
#define wxLongLongSuffix LL
|
||||
#define wxLongLongFmtSpec wxT("ll")
|
||||
#define wxLongLongFmtSpec "ll"
|
||||
#elif defined(__MINGW32__)
|
||||
#define wxLongLong_t long long
|
||||
#define wxLongLongSuffix ll
|
||||
#define wxLongLongFmtSpec wxT("I64")
|
||||
#define wxLongLongFmtSpec "I64"
|
||||
#elif defined(__MWERKS__)
|
||||
#if __option(longlong)
|
||||
#define wxLongLong_t long long
|
||||
#define wxLongLongSuffix ll
|
||||
#define wxLongLongFmtSpec wxT("ll")
|
||||
#define wxLongLongFmtSpec "ll"
|
||||
#else
|
||||
#error "The 64 bit integer support in CodeWarrior has been disabled."
|
||||
#error "See the documentation on the 'longlong' pragma."
|
||||
@ -1011,7 +1011,7 @@ typedef wxUint32 wxDword;
|
||||
#define wxLongLong_t long long
|
||||
#endif /* __WXPALMOS6__ */
|
||||
#define wxLongLongSuffix ll
|
||||
#define wxLongLongFmtSpec wxT("ll")
|
||||
#define wxLongLongFmtSpec "ll"
|
||||
#elif defined(__VISAGECPP__) && __IBMCPP__ >= 400
|
||||
#define wxLongLong_t long long
|
||||
#elif (defined(SIZEOF_LONG_LONG) && SIZEOF_LONG_LONG >= 8) || \
|
||||
@ -1021,11 +1021,11 @@ typedef wxUint32 wxDword;
|
||||
(defined(__DJGPP__) && __DJGPP__ >= 2)
|
||||
#define wxLongLong_t long long
|
||||
#define wxLongLongSuffix ll
|
||||
#define wxLongLongFmtSpec wxT("ll")
|
||||
#define wxLongLongFmtSpec "ll"
|
||||
#elif defined(SIZEOF_LONG) && (SIZEOF_LONG == 8)
|
||||
#define wxLongLong_t long
|
||||
#define wxLongLongSuffix l
|
||||
#define wxLongLongFmtSpec wxT("l")
|
||||
#define wxLongLongFmtSpec "l"
|
||||
#define wxLongLongIsLong
|
||||
#endif
|
||||
|
||||
|
@ -2071,14 +2071,12 @@ public:
|
||||
// insert a long long if they exist and aren't longs
|
||||
wxString& operator<<(wxLongLong_t ll)
|
||||
{
|
||||
const wxChar *fmt = wxT("%") wxLongLongFmtSpec wxT("d");
|
||||
return (*this) << Format(fmt, ll);
|
||||
return (*this) << Format("%" wxLongLongFmtSpec "d", ll);
|
||||
}
|
||||
// insert an unsigned long long
|
||||
wxString& operator<<(wxULongLong_t ull)
|
||||
{
|
||||
const wxChar *fmt = wxT("%") wxLongLongFmtSpec wxT("u");
|
||||
return (*this) << Format(fmt , ull);
|
||||
return (*this) << Format("%" wxLongLongFmtSpec "u" , ull);
|
||||
}
|
||||
#endif // wxLongLong_t && !wxLongLongIsLong
|
||||
// insert a float into string
|
||||
|
@ -1915,7 +1915,7 @@ I am ready for my first lesson today.");
|
||||
{
|
||||
wxChar buf[200];
|
||||
|
||||
wxSprintf(buf, wxT("%07") wxLongLongFmtSpec wxT("o"), wxLL(040000000000));
|
||||
wxSprintf(buf, "%07" wxLongLongFmtSpec "o", wxLL(040000000000));
|
||||
#if 0
|
||||
// for some reason below line fails under Borland
|
||||
wxPrintf (wxT("sprintf (buf, \"%%07Lo\", 040000000000ll) = %s"), buf);
|
||||
|
@ -74,7 +74,7 @@
|
||||
typedef wxLongLong wxTimerTick_t;
|
||||
|
||||
#if wxUSE_LONGLONG_WX
|
||||
#define wxTimerTickFmtSpec wxLongLongFmtSpec wxT("d")
|
||||
#define wxTimerTickFmtSpec wxLongLongFmtSpec "d"
|
||||
#define wxTimerTickPrintfArg(tt) (tt.GetValue())
|
||||
#else // using native wxLongLong
|
||||
#define wxTimerTickFmtSpec wxT("s")
|
||||
|
@ -281,7 +281,7 @@ wxDbgHelpDLL::DumpBaseType(BasicType bt, DWORD64 length, PVOID pAddress)
|
||||
}
|
||||
else // opaque 64 bit value
|
||||
{
|
||||
s.Printf(wxT("%#" wxLongLongFmtSpec wxT("x")), *(PDWORD *)pAddress);
|
||||
s.Printf("%#" wxLongLongFmtSpec "x", *(PDWORD *)pAddress);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -359,14 +359,14 @@ static const wxChar* gs_uintTemplates32[wxPG_UINT_TEMPLATE_MAX] = {
|
||||
};
|
||||
|
||||
static const wxChar* gs_uintTemplates64[wxPG_UINT_TEMPLATE_MAX] = {
|
||||
wxT("%") wxLongLongFmtSpec wxT("x"),
|
||||
wxT("0x%") wxLongLongFmtSpec wxT("x"),
|
||||
wxT("$%") wxLongLongFmtSpec wxT("x"),
|
||||
wxT("%") wxLongLongFmtSpec wxT("X"),
|
||||
wxT("0x%") wxLongLongFmtSpec wxT("X"),
|
||||
wxT("$%") wxLongLongFmtSpec wxT("X"),
|
||||
wxT("%") wxLongLongFmtSpec wxT("u"),
|
||||
wxT("%") wxLongLongFmtSpec wxT("o")
|
||||
"%" wxLongLongFmtSpec "x",
|
||||
"0x%" wxLongLongFmtSpec "x",
|
||||
"$%" wxLongLongFmtSpec "x",
|
||||
"%" wxLongLongFmtSpec "X",
|
||||
"0x%" wxLongLongFmtSpec "X",
|
||||
"$%" wxLongLongFmtSpec "X",
|
||||
"%" wxLongLongFmtSpec "u",
|
||||
"%" wxLongLongFmtSpec "o"
|
||||
};
|
||||
|
||||
WX_PG_IMPLEMENT_PROPERTY_CLASS(wxUIntProperty,wxPGProperty,
|
||||
|
Loading…
Reference in New Issue
Block a user