# HG changeset patch # User Geoff Voelker # Date 907913392 0 # Node ID 4587be644789be0eaff38d334281a4154fb93a3a # Parent 37457777218a95b352ebcbf28ef7490895c39014 (x_create_bitmap_from_file): Skip special files. diff -r 37457777218a -r 4587be644789 src/w32fns.c --- a/src/w32fns.c Fri Oct 09 01:55:02 1998 +0000 +++ b/src/w32fns.c Fri Oct 09 06:09:52 1998 +0000 @@ -442,6 +442,9 @@ fd = openp (Vx_bitmap_file_path, file, "", &found, 0); if (fd < 0) return -1; + /* LoadLibraryEx won't handle special files handled by Emacs handler. */ + if (fd == 0) + return -1; close (fd); filename = (char *) XSTRING (found)->data; @@ -1298,6 +1301,38 @@ return ret; } +COLORREF +w32_color_map_lookup (colorname) + char *colorname; +{ + Lisp_Object tail, ret = Qnil; + + BLOCK_INPUT; + + for (tail = Vw32_color_map; !NILP (tail); tail = Fcdr (tail)) + { + register Lisp_Object elt, tem; + + elt = Fcar (tail); + if (!CONSP (elt)) continue; + + tem = Fcar (elt); + + if (lstrcmpi (XSTRING (tem)->data, colorname) == 0) + { + ret = XUINT (Fcdr (elt)); + break; + } + + QUIT; + } + + + UNBLOCK_INPUT; + + return ret; +} + COLORREF x_to_w32_color (colorname) char * colorname;