(g2-UU+5B73): Add `=decomposition@hanyo-denshi'.
[chise/xemacs-chise.git.1] / src / syswindows.h
index 0b505cb..131c155 100644 (file)
@@ -57,8 +57,7 @@ Boston, MA 02111-1307, USA.  */
 
 #include <windows.h>
 
-#if (defined (CYGWIN) || defined(MINGW)) && \
-       CYGWIN_VERSION_DLL_MAJOR < 21
+#if defined (CYGWIN) && CYGWIN_VERSION_DLL_MAJOR < 21
 extern BOOL WINAPI DdeFreeStringHandle(DWORD,HSZ);
 extern BOOL WINAPI PlaySound(LPCSTR,HMODULE,DWORD);
 #define stricmp strcasecmp
@@ -75,6 +74,7 @@ extern BOOL WINAPI PlaySound(LPCSTR,HMODULE,DWORD);
 #define Status int
 #endif
 #include <mmsystem.h>
+#include <shlobj.h>
 #include <shellapi.h>
 #include <ddeml.h>
 #endif
@@ -107,6 +107,17 @@ extern BOOL WINAPI PlaySound(LPCSTR,HMODULE,DWORD);
 #define PHYSICALOFFSETY 113
 #endif
 
+/* shlobj.h defines. */
+#ifndef BIF_EDITBOX
+#define BIF_EDITBOX 0x10
+#endif
+#ifndef BIF_VALIDATE
+#define BIF_VALIDATE 0x20
+#endif
+#ifndef BFFM_VALIDATEFAILED
+#define BFFM_VALIDATEFAILED 3
+#endif
+
 /* windows.h defines. */
 #if defined (CYGWIN) && (CYGWIN_VERSION_DLL_MAJOR < 20)
 typedef NMHDR *LPNMHDR;
@@ -169,6 +180,9 @@ typedef NMHDR *LPNMHDR;
 #ifndef MAC_CHARSET
 #define MAC_CHARSET            77
 #endif
+#ifndef LOCALE_RETURN_NUMBER
+#define LOCALE_RETURN_NUMBER   0x20000000
+#endif
 
 /***************************************************************/
 
@@ -176,7 +190,7 @@ typedef NMHDR *LPNMHDR;
 
 #include <wchar.h>
 
-#ifdef CYGWIN
+#if defined (CYGWIN) && (CYGWIN_VERSION_DLL_COMBINED < 190)
 
 /* All but wcscmp and wcslen left out of Cygwin headers -- but present
    in /usr/include/mingw32/string.h! */
@@ -239,10 +253,15 @@ Lisp_Object tstr_to_local_file_format (Extbyte *pathout);
 #define LOCAL_TO_WIN32_FILE_FORMAT(path, pathout)                      \
 do {                                                                   \
   Lisp_Object ltwff1 = (path);                                         \
-  int ltwff2 =                                                         \
-    cygwin_posix_to_win32_path_list_buf_size (XSTRING_DATA (ltwff1));  \
-  pathout = (Bufbyte *) alloca (ltwff2);                               \
-  cygwin_posix_to_win32_path_list (XSTRING_DATA (ltwff1), pathout);    \
+  Bufbyte* ltwffp = XSTRING_DATA (ltwff1);                             \
+  if (isalpha (ltwffp[0]) && (IS_DEVICE_SEP (ltwffp[1])))                      \
+    pathout = ltwffp;                                                  \
+  else {                                                                       \
+    int ltwff2 =                                                               \
+      cygwin_posix_to_win32_path_list_buf_size (ltwffp);       \
+    pathout = (Bufbyte *) alloca (ltwff2);                             \
+    cygwin_posix_to_win32_path_list (ltwffp, pathout); \
+  }                                                                    \
 } while (0)
 #else
 #define LOCAL_TO_WIN32_FILE_FORMAT(path, pathout)      \