X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fd242375198e16a92283f633dfe0bdb80d1ffa58..0425151023593cb31da0ee0a652da173ca9abfde:/src/common/strconv.cpp diff --git a/src/common/strconv.cpp b/src/common/strconv.cpp index 29710e6d04..2279100d93 100644 --- a/src/common/strconv.cpp +++ b/src/common/strconv.cpp @@ -37,7 +37,10 @@ #include "wx/msw/private.h" #endif +#ifndef __WXWINCE__ #include +#endif + #include #include #include @@ -275,48 +278,6 @@ const wxCharBuffer wxMBConv::cWC2MB(const wchar_t *pwz) const return buf; } -// ---------------------------------------------------------------------------- -// standard gdk conversion -// ---------------------------------------------------------------------------- - -#ifdef __WXGTK12__ - -WXDLLIMPEXP_DATA_BASE(wxMBConvGdk) wxConvGdk; - -#include - -size_t wxMBConvGdk::MB2WC(wchar_t *buf, const char *psz, size_t n) const -{ - if (buf) - { - return gdk_mbstowcs((GdkWChar *)buf, psz, n); - } - else - { - GdkWChar *nbuf = new GdkWChar[n=strlen(psz)]; - size_t len = gdk_mbstowcs(nbuf, psz, n); - delete[] nbuf; - return len; - } -} - -size_t wxMBConvGdk::WC2MB(char *buf, const wchar_t *psz, size_t n) const -{ - char *mbstr = gdk_wcstombs((GdkWChar *)psz); - size_t len = mbstr ? strlen(mbstr) : 0; - if (buf) - { - if (len > n) - len = n; - memcpy(buf, psz, len); - if (len < n) - buf[len] = 0; - } - return len; -} - -#endif // GTK > 1.0 - // ---------------------------------------------------------------------------- // UTF-7 // ---------------------------------------------------------------------------- @@ -885,6 +846,8 @@ public: // were we initialized successfully? bool m_ok; + + DECLARE_NO_COPY_CLASS(EC_CharSet) }; #endif // wxUSE_FONTMAP