2007-11-14 19:00 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)

* harbour/include/hbwince.h
  * harbour/source/common/hbwince.c
  * harbour/utils/hbver/hbverfix.c
    * modified for clean compilation with POCC/XCC and ARM processors
This commit is contained in:
Przemyslaw Czerpak
2007-11-14 18:00:38 +00:00
parent c4ec7e4711
commit 1a936ea93a
4 changed files with 44 additions and 2 deletions

View File

@@ -8,6 +8,12 @@
2002-12-01 13:30 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2007-11-14 19:00 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbwince.h
* harbour/source/common/hbwince.c
* harbour/utils/hbver/hbverfix.c
* modified for clean compilation with POCC/XCC and ARM processors
2007-11-14 17:07 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/harbour-ce-spec
* harbour/harbour-w32-spec

View File

@@ -144,6 +144,17 @@ extern char *strerror( int errnum );
BOOL WINAPI GetKeyboardState( PBYTE p );
BOOL WINAPI SetKeyboardState( PBYTE p );
#if defined( __POCC__ ) || defined( __XCC__ )
#define GlobalAlloc(flags, cb) LocalAlloc(flags, cb)
#define GlobalLock(lp) LocalLock(lp)
#define GlobalUnlock(lp) LocalUnlock(lp)
#define GlobalSize(lp) LocalSize(lp)
#define GlobalFree(h) LocalFree(h)
#define GlobalReAlloc(h, cb, flags) LocalReAlloc(h, cb, flags)
#define GlobalHandle(lp) LocalHandle(lp)
#define GlobalFlags(lp) LocalFlags(lp)
#endif
#endif /* HB_OS_WIN_32_USED && _MSC_VER */
#endif /* HB_WINCE */

View File

@@ -653,7 +653,7 @@ BOOL WINAPI SetKeyboardState( PBYTE p )
return FALSE;
}
#ifndef _MSC_VER
#if !defined( _MSC_VER ) || defined( __POCC__ ) || defined( __XCC__ )
PVOID WINAPI LocalLock( HLOCAL h )
{
HB_SYMBOL_UNUSED( h );
@@ -667,7 +667,7 @@ BOOL WINAPI LocalUnlock( HLOCAL h )
return FALSE;
}
#endif /* _MSC_VER */
#endif /* !_MSC_VER || __POCC__ || __XCC__ */
#endif /* UNICODE */

View File

@@ -74,6 +74,10 @@
#define MAX_BUF_LEN 4096
#if defined(HB_WINCE)
#define hb_xgrab(x) malloc(x)
#define hb_xfree(x) free(x)
wchar_t *hb_mbtowc( const char * srcA )
{
DWORD length;
@@ -86,6 +90,23 @@ wchar_t *hb_mbtowc( const char * srcA )
return dstW;
}
char *hb_wctomb( const wchar_t *srcW )
{
DWORD length;
char *dstA;
length = WideCharToMultiByte( CP_ACP, 0, srcW, -1, NULL, 0, NULL, NULL );
dstA = ( char * ) hb_xgrab( length + 1 );
WideCharToMultiByte( CP_ACP, 0, srcW, -1, dstA, length + 1, NULL, NULL );
return dstA;
}
void hb_wctombget( char *dstA, const wchar_t *srcW, unsigned long ulLen )
{
WideCharToMultiByte( CP_ACP, 0, srcW, ulLen, dstA, ulLen, NULL, NULL );
}
int remove( const char * path )
{
wchar_t * wpath;
@@ -410,3 +431,7 @@ int main( int argc, char * argv[] )
}
return 0;
}
#if defined( HB_WINCE ) && !defined( __CEGCC__ )
# include "hbwmain.c"
#endif