[shlwapi] forward to user32 when appropriate
Thomas Weidenmueller
wine-patches at reactsoft.com
Wed Feb 16 06:00:53 CST 2005
This patch removes the direct dependencies to libunicode by forwarding
to user32. I'm sorry for submitting a few useless patches previously.
Best Regards,
Thomas
-------------- next part --------------
Index: dlls/shlwapi/ordinal.c
===================================================================
RCS file: /home/wine/wine/dlls/shlwapi/ordinal.c,v
retrieving revision 1.104
diff -u -r1.104 ordinal.c
--- dlls/shlwapi/ordinal.c 15 Feb 2005 21:51:07 -0000 1.104
+++ dlls/shlwapi/ordinal.c 16 Feb 2005 11:58:08 -0000
@@ -681,74 +681,6 @@
}
/*************************************************************************
- * @ [SHLWAPI.25]
- *
- * Determine if a Unicode character is alphabetic.
- *
- * PARAMS
- * wc [I] Character to check.
- *
- * RETURNS
- * TRUE, if wc is alphabetic,
- * FALSE otherwise.
- */
-BOOL WINAPI IsCharAlphaWrapW(WCHAR wc)
-{
- return (get_char_typeW(wc) & C1_ALPHA) != 0;
-}
-
-/*************************************************************************
- * @ [SHLWAPI.26]
- *
- * Determine if a Unicode character is upper-case.
- *
- * PARAMS
- * wc [I] Character to check.
- *
- * RETURNS
- * TRUE, if wc is upper-case,
- * FALSE otherwise.
- */
-BOOL WINAPI IsCharUpperWrapW(WCHAR wc)
-{
- return (get_char_typeW(wc) & C1_UPPER) != 0;
-}
-
-/*************************************************************************
- * @ [SHLWAPI.27]
- *
- * Determine if a Unicode character is lower-case.
- *
- * PARAMS
- * wc [I] Character to check.
- *
- * RETURNS
- * TRUE, if wc is lower-case,
- * FALSE otherwise.
- */
-BOOL WINAPI IsCharLowerWrapW(WCHAR wc)
-{
- return (get_char_typeW(wc) & C1_LOWER) != 0;
-}
-
-/*************************************************************************
- * @ [SHLWAPI.28]
- *
- * Determine if a Unicode character is alphabetic or a digit.
- *
- * PARAMS
- * wc [I] Character to check.
- *
- * RETURNS
- * TRUE, if wc is alphabetic or a digit,
- * FALSE otherwise.
- */
-BOOL WINAPI IsCharAlphaNumericWrapW(WCHAR wc)
-{
- return (get_char_typeW(wc) & (C1_ALPHA|C1_DIGIT)) != 0;
-}
-
-/*************************************************************************
* @ [SHLWAPI.29]
*
* Determine if a Unicode character is a space.
@@ -762,7 +694,9 @@
*/
BOOL WINAPI IsCharSpaceW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_SPACE) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_SPACE);
}
/*************************************************************************
@@ -780,7 +714,9 @@
*/
BOOL WINAPI IsCharBlankW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_BLANK) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_BLANK);
}
/*************************************************************************
@@ -797,7 +733,9 @@
*/
BOOL WINAPI IsCharPunctW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_PUNCT) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_PUNCT);
}
/*************************************************************************
@@ -814,7 +752,9 @@
*/
BOOL WINAPI IsCharCntrlW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_CNTRL) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_CNTRL);
}
/*************************************************************************
@@ -831,7 +771,9 @@
*/
BOOL WINAPI IsCharDigitW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_DIGIT) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_DIGIT);
}
/*************************************************************************
@@ -848,7 +790,9 @@
*/
BOOL WINAPI IsCharXDigitW(WCHAR wc)
{
- return (get_char_typeW(wc) & C1_XDIGIT) != 0;
+ WORD CharType;
+
+ return GetStringTypeW(CT_CTYPE1, &wc, 1, &CharType) && (CharType & C1_XDIGIT);
}
/*************************************************************************
Index: dlls/shlwapi/shlwapi.spec
===================================================================
RCS file: /home/wine/wine/dlls/shlwapi/shlwapi.spec,v
retrieving revision 1.98
diff -u -r1.98 shlwapi.spec
--- dlls/shlwapi/shlwapi.spec 3 Feb 2005 13:34:05 -0000 1.98
+++ dlls/shlwapi/shlwapi.spec 16 Feb 2005 01:32:37 -0000
@@ -22,10 +22,10 @@
22 stdcall -noname SHFindDataBlock(ptr long)
23 stdcall -noname SHStringFromGUIDA(ptr ptr long)
24 stdcall -noname SHStringFromGUIDW(ptr ptr long)
-25 stdcall -noname IsCharAlphaWrapW(long)
-26 stdcall -noname IsCharUpperWrapW(long)
-27 stdcall -noname IsCharLowerWrapW(long)
-28 stdcall -noname IsCharAlphaNumericWrapW(long)
+25 stdcall -noname IsCharAlphaWrapW(long) user32.IsCharAlphaW
+26 stdcall -noname IsCharUpperWrapW(long) user32.IsCharUpperW
+27 stdcall -noname IsCharLowerWrapW(long) user32.IsCharLowerW
+28 stdcall -noname IsCharAlphaNumericWrapW(long) user32.IsCharAlphaNumericW
29 stdcall -noname IsCharSpaceW(long)
30 stdcall -noname IsCharBlankW(long)
31 stdcall -noname IsCharPunctW(long)
More information about the wine-patches
mailing list