X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d545f8030a9ba07dcd5cd146dae2898ced7a48c1..cfa3d7ba83b57ac7a9fa6b79ae73ef9cebcb55f4:/src/common/utilscmn.cpp diff --git a/src/common/utilscmn.cpp b/src/common/utilscmn.cpp index 8a0dfa3b2f..21895181cb 100644 --- a/src/common/utilscmn.cpp +++ b/src/common/utilscmn.cpp @@ -140,6 +140,15 @@ void wxDecToHex(int dec, wxChar *buf) buf[2] = 0; } +// Convert decimal integer to 2 characters +void wxDecToHex(int dec, char* ch1, char* ch2) +{ + int firstDigit = (int)(dec/16.0); + int secondDigit = (int)(dec - (firstDigit*16.0)); + (*ch1) = (char) hexArray[firstDigit]; + (*ch2) = (char) hexArray[secondDigit]; +} + // Convert decimal integer to 2-character hex string wxString wxDecToHex(int dec) { @@ -821,7 +830,7 @@ bool wxLaunchDefaultBrowser(const wxString& urlOrig, int flags) wxLogDebug(wxT("ICStart error %d"), (int) err); return false; } -#else +#else // (non-Mac, non-MSW) #ifdef __UNIX__