mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 11:56:45 +00:00
implemented IsDBCSLeadByte() and IsDBCSLeadByteEx()
svn path=/trunk/; revision=10953
This commit is contained in:
parent
fa965094ed
commit
bd7af734b8
2 changed files with 54 additions and 33 deletions
|
@ -879,4 +879,57 @@ GetOEMCP (VOID)
|
||||||
return OemCodePage.CodePageTable.CodePage;
|
return OemCodePage.CodePageTable.CodePage;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline BOOL
|
||||||
|
IntIsLeadByte(PCPTABLEINFO TableInfo, UCHAR Ch)
|
||||||
|
{
|
||||||
|
if(TableInfo->MaximumCharacterSize == 2)
|
||||||
|
{
|
||||||
|
UINT i;
|
||||||
|
for(i = 0; i < MAXIMUM_LEADBYTES; i++)
|
||||||
|
{
|
||||||
|
if(TableInfo->LeadByte[i] == Ch)
|
||||||
|
{
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @implemented
|
||||||
|
*/
|
||||||
|
BOOL
|
||||||
|
STDCALL
|
||||||
|
IsDBCSLeadByte (
|
||||||
|
BYTE TestChar
|
||||||
|
)
|
||||||
|
{
|
||||||
|
return IntIsLeadByte(&AnsiCodePage.CodePageTable, (UCHAR)TestChar);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @implemented
|
||||||
|
*/
|
||||||
|
BOOL
|
||||||
|
STDCALL
|
||||||
|
IsDBCSLeadByteEx (
|
||||||
|
UINT CodePage,
|
||||||
|
BYTE TestChar
|
||||||
|
)
|
||||||
|
{
|
||||||
|
PCODEPAGE_ENTRY CodePageEntry;
|
||||||
|
|
||||||
|
CodePageEntry = IntGetCodePageEntry(CodePage);
|
||||||
|
if(CodePageEntry != NULL)
|
||||||
|
{
|
||||||
|
return IntIsLeadByte(&CodePageEntry->CodePageTable, (UCHAR)TestChar);
|
||||||
|
}
|
||||||
|
|
||||||
|
SetLastError(ERROR_INVALID_PARAMETER);
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* EOF */
|
/* EOF */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: stubs.c,v 1.82 2004/08/29 14:45:55 weiden Exp $
|
/* $Id: stubs.c,v 1.83 2004/09/21 17:41:24 weiden Exp $
|
||||||
*
|
*
|
||||||
* KERNEL32.DLL stubs (unimplemented functions)
|
* KERNEL32.DLL stubs (unimplemented functions)
|
||||||
* Remove from this file, if you implement them.
|
* Remove from this file, if you implement them.
|
||||||
|
@ -363,38 +363,6 @@ GetVDMCurrentDirectories (
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef _OLE2NLS_IN_BUILD_
|
|
||||||
|
|
||||||
/*
|
|
||||||
* @unimplemented
|
|
||||||
*/
|
|
||||||
BOOL
|
|
||||||
STDCALL
|
|
||||||
IsDBCSLeadByte (
|
|
||||||
BYTE TestChar
|
|
||||||
)
|
|
||||||
{
|
|
||||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* @unimplemented
|
|
||||||
*/
|
|
||||||
BOOL
|
|
||||||
STDCALL
|
|
||||||
IsDBCSLeadByteEx (
|
|
||||||
UINT CodePage,
|
|
||||||
BYTE TestChar
|
|
||||||
)
|
|
||||||
{
|
|
||||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @unimplemented
|
* @unimplemented
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue