reactos/lib/kernel32/misc
diff -u -r1.4 -r1.5
--- nls.c 31 Aug 2004 19:54:14 -0000 1.4
+++ nls.c 21 Sep 2004 17:41:24 -0000 1.5
@@ -879,4 +879,57 @@
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 */
reactos/lib/kernel32/misc
diff -u -r1.82 -r1.83
--- stubs.c 29 Aug 2004 14:45:55 -0000 1.82
+++ stubs.c 21 Sep 2004 17:41:24 -0000 1.83
@@ -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)
* Remove from this file, if you implement them.
@@ -363,38 +363,6 @@
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