]> git.eshelyaron.com Git - emacs.git/commit
Restore functionality on Windows 98
authorPo Lu <luangruo@yahoo.com>
Sun, 23 Jun 2024 08:28:22 +0000 (16:28 +0800)
committerEshel Yaron <me@eshelyaron.com>
Sun, 30 Jun 2024 21:01:56 +0000 (23:01 +0200)
commit6843e3677ca8972d13d29f35fadc26ddc9f3723a
tree9b1cea842848225869099e85f9a5e204df62f776
parent1a3ba9426b1c4973799548416878e3576b751cf0
Restore functionality on Windows 98

* configure.ac (W32_LIBS): Don't link with -lusp10 on non-Cygwin
systems.

* src/emacs.c (main): Call globals_of_w32 before the startup
directory is initialized.

* src/w32.c (maybe_load_unicows_dll): Call
load_unicows_dll_for_w32fns.

* src/w32.h: Update prototypes.

* src/w32fns.c (Fx_create_frame, w32_create_tip_frame): Do not
register the Uniscribe font driver when unavailable.
(pfnSHFileOperationW): New function pointer.
(Fsystem_move_file_to_trash): Load UNICOWS.DLL if not yet
loaded.  Call SHFileOperationW through said function pointer.
(pfnShellExecuteExW): New function pointer.
(Fw32_shell_execute) [!CYGWIN]: Load UNICOWS.DLL if not yet
loaded.  Call ShellExecuteExW through said function pointer.
(pfnShell_NotifyIconW): New function pointer.
(add_tray_notification, delete_tray_notification): Call
Shell_NotifyIconW through said function pointer.
(Fw32_notification_notify): Load UNICOWS.DLL.
(Fw32_notification_close): Return if Shell_NotifyIconW is
unavailable, as when UNICOWS.DLL has yet to be loaded.
(load_unicows_dll_for_w32fns): New function.

* src/w32notify.c (pfnReadDirectoryChangesW): New function
pointer.
(watch_completion, remove_watch, Fw32notify_add_watch)
(Fw32notify_rm_watch, Fw32notify_valid_p): Call
ReadDirectoryChangesW through said function pointer, and assert
its presence.
(globals_of_w32notify): Load ReadDirectoryChangesW from
KERNEL32.DLL.

* src/w32uniscribe.c (pfnScriptItemize, pfnScriptShape)
(pfnScriptPlace, pfnScriptGetGlyphABCWidth, pfnScriptFreeCache)
(pfnScriptGetCMap): New function pointers.
(uniscribe_close, uniscribe_shape, uniscribe_encode_char)
(uniscribe_check_otf_1): Call Uniscribe functions through the
same.
(syms_of_w32uniscribe_for_pdumper): Load Uniscribe library and
required functions from the same, and if unavailable, return
while leaving uniscribe_available intact.  On Cygwin, simply
assign USP10.DLL functions to the said new function pointers.

(cherry picked from commit 18e7a9f3d0c27385f8efeb2b1ef80b3446dca288)
configure.ac
src/emacs.c
src/w32.c
src/w32.h
src/w32fns.c
src/w32notify.c
src/w32uniscribe.c