Initial import

This commit is contained in:
2026-08-28 23:39:13 +02:00
parent 2349541c27
commit b8a522c1de
9 changed files with 859 additions and 1 deletions
+39
View File
@@ -0,0 +1,39 @@
#lang racket/base
(require racket/runtime-path)
(provide mk-tray
tray-close
tray-set-icon!
tray-set-menu!)
(define (unsupported who . _args)
(error who "not supported on this operating system: ~a" (system-type 'os*)))
(define mk-tray
(λ args
(apply unsupported 'mk-tray args)))
(define tray-close
(λ args
(apply unsupported 'tray-close args)))
(define tray-set-icon!
(λ args
(apply unsupported 'tray-set-icon! args)))
(define tray-set-menu!
(λ args
(apply unsupported 'tray-set-menu! args)))
(define-runtime-module-path windows-module "private/windows.rkt")
(when (eq? (system-type 'os*) 'windows)
(set! mk-tray
(dynamic-require windows-module 'mk-tray))
(set! tray-close
(dynamic-require windows-module 'tray-close))
(set! tray-set-icon!
(dynamic-require windows-module 'tray-set-icon!))
(set! tray-set-menu!
(dynamic-require windows-module 'tray-set-menu!)))