sequences locals system splitting tools.deploy.backend
tools.deploy.config tools.deploy.config.editor assocs hashtables
prettyprint combinators windows.kernel32 windows.shell32 windows.user32
-alien.c-types vocabs.metadata vocabs.loader tools.deploy.windows.ico ;
+alien.c-types vocabs.metadata vocabs.loader tools.deploy.windows.ico
+io.files.windows.nt ;
IN: tools.deploy.windows
CONSTANT: app-icon-resource-id "APPICON"
dup copy-dll
deploy-ui? get ".exe" ".com" ? copy-vm ;
+: open-in-explorer ( dir -- )
+ [ f "open" ] dip absolute-path normalize-separators
+ f f SW_SHOWNORMAL ShellExecute drop ;
+
: embed-ico ( vm vocab -- )
dup vocab-windows-icon-path vocab-append-path dup exists?
[ binary file-contents app-icon-resource-id embed-icon-resource ]
FUNCTION: HINSTANCE ShellExecuteW ( HWND hwnd, LPCTSTR lpOperation, LPCTSTR lpFile, LPCTSTR lpParameters, LPCTSTR lpDirectory, INT nShowCmd ) ;
ALIAS: ShellExecute ShellExecuteW
-: open-in-explorer ( dir -- )
- [ f "open" ] dip absolute-path f f SW_SHOWNORMAL ShellExecute drop ;
-
: shell32-directory ( n -- str )
f swap f SHGFP_TYPE_DEFAULT
MAX_UNICODE_PATH <ushort-array>