! Copyright (C) 2010 Joe Groff.
-! See http://factorcode.org/license.txt for BSD license.
+! See https://factorcode.org/license.txt for BSD license.
USING: alien.c-types alien.data alien.destructors alien.syntax
-classes.struct kernel literals math windows.com windows.com.syntax
-windows.kernel32 windows.ole32 windows.types ;
+classes.struct init kernel literals math namespaces windows.com
+windows.com.syntax windows.kernel32 windows.ole32 windows.types ;
FROM: alien.c-types => float ;
IN: windows.gdiplus
GdiplusShutdown ;
DESTRUCTOR: stop-gdi+
+
+SYMBOL: gdi-token
+
+STARTUP-HOOK: [ start-gdi+ gdi-token set-global ]
+
+SHUTDOWN-HOOK: [ gdi-token get-global [ stop-gdi+ ] when* ]