]>
git.saurik.com Git - wxWidgets.git/blob - src/msw/wince/crt.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/msw/wince/crt.cpp
3 // Purpose: Implementation of CRT functions missing under Windows CE
4 // Author: Vadim Zeitlin
7 // Copyright: (c) 2004 Vadim Zeitlin <vadim@wxwindows.org>
8 // Licence: wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
11 #include "wx/wxprec.h"
21 #include "wx/msw/wince/missing.h"
24 bsearch(const void *key
, const void *base
, size_t num
, size_t size
,
25 int (wxCMPFUNC_CONV
*cmp
)(const void *, const void *))
30 char *lo
= (char *)base
;
31 char *hi
= lo
+ num
*size
;
34 mid
= lo
+ (hi
- lo
)/2;
36 res
= (*cmp
)(key
, mid
);
53 name
= wxTheApp
->GetAppDisplayName();
55 name
= L
"wxWidgets Application";
57 MessageBox(NULL
, L
"Abnormal program termination", name
, MB_ICONHAND
| MB_OK
);
64 char *getenv(const char * WXUNUSED(name
))
66 // no way to implement it in Unicode-only environment without using
67 // wxCharBuffer and it is of no use in C code which uses this function
72 int wxCRT_Rename(const wchar_t *src
, const wchar_t *dst
)
74 return ::MoveFile(src
, dst
) ? 0 : -1;
77 int wxCRT_Remove(const wchar_t *path
)
79 return ::DeleteFile(path
) ? 0 : -1;