Compare commits
7 Commits
master
...
windows-hi
Author | SHA1 | Date |
---|---|---|
|
40ef5594cb | |
|
ef0f56e4b7 | |
|
32795ecf03 | |
|
0f796b922b | |
|
81ff054785 | |
|
4785479ea0 | |
|
56a1ecc0cb |
12
Nmakefile
12
Nmakefile
|
@ -132,11 +132,19 @@ libfactor-ffi-test.dll: vm/ffi_test.obj
|
|||
factor.dll.lib: $(DLL_OBJS)
|
||||
link $(LINK_FLAGS) /implib:factor.dll.lib /out:factor.dll /dll $(DLL_OBJS)
|
||||
|
||||
factor.com: $(EXE_OBJS) $(DLL_OBJS)
|
||||
# If we ``link`` factor.com and then ``mt`` it in the same rule (for retina support)
|
||||
# then factor.com is still open and ``mt`` fails
|
||||
# sleep hack fixes it...
|
||||
factor.com :: $(EXE_OBJS) $(DLL_OBJS)
|
||||
link $(LINK_FLAGS) /out:factor.com /SUBSYSTEM:$(SUBSYSTEM_COM_FLAGS) $(EXE_OBJS) $(DLL_OBJS)
|
||||
factor.com ::
|
||||
mt -manifest factor.exe.manifest -outputresource:factor.com;#1
|
||||
|
||||
factor.exe: $(EXE_OBJS) $(DLL_OBJS)
|
||||
factor.exe :: $(EXE_OBJS) $(DLL_OBJS)
|
||||
link $(LINK_FLAGS) /out:factor.exe /SUBSYSTEM:$(SUBSYSTEM_EXE_FLAGS) $(EXE_OBJS) $(DLL_OBJS)
|
||||
factor.exe ::
|
||||
mt -manifest factor.exe.manifest -outputresource:factor.exe;#1
|
||||
|
||||
|
||||
all: factor.com factor.exe factor.dll.lib libfactor-ffi-test.dll
|
||||
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Doug Coleman
|
|
@ -0,0 +1 @@
|
|||
windows
|
|
@ -0,0 +1,11 @@
|
|||
! Copyright (C) 2018 Doug Coleman.
|
||||
! See http://factorcode.org/license.txt for BSD license.
|
||||
USING: alien.c-types alien.data arrays classes.struct kernel
|
||||
windows.errors windows.shcore windows.types windows.user32 ;
|
||||
IN: windows.screens
|
||||
|
||||
: get-dpi ( -- dpi )
|
||||
0 0 POINT <struct-boa> 0 MonitorFromPoint
|
||||
MDT_EFFECTIVE_DPI
|
||||
0 uint <ref> 0 uint <ref> [ GetDpiForMonitor win32-error=0/f ] 2keep
|
||||
[ uint deref ] bi@ 2array ;
|
|
@ -0,0 +1 @@
|
|||
Benjamin Pollack
|
|
@ -0,0 +1 @@
|
|||
windows
|
|
@ -0,0 +1,103 @@
|
|||
! Copyright (C) 2017 Benjamin Pollack, Doug Coleman.
|
||||
! See http://factorcode.org/license.txt for BSD license.
|
||||
USING: alien.syntax windows.types ;
|
||||
IN: windows.shcore
|
||||
|
||||
LIBRARY: shcore
|
||||
|
||||
ENUM: MONITOR_DPI_TYPE
|
||||
MDT_EFFECTIVE_DPI
|
||||
MDT_ANGULAR_DPI
|
||||
MDT_RAW_DPI
|
||||
{ MDT_DEFAULT 0 } ;
|
||||
|
||||
! CommandLineToArgvW
|
||||
! CreateRandomAccessStreamOnFile
|
||||
! CreateRandomAccessStreamOverStream
|
||||
! CreateStreamOverRandomAccessStream
|
||||
! DllCanUnloadNow
|
||||
! DllGetActivationFactory
|
||||
! DllGetClassObject
|
||||
! GetCurrentProcessExplicitAppUserModelID
|
||||
FUNCTION: HRESULT GetDpiForMonitor ( HMONITOR hMonitor, MONITOR_DPI_TYPE dpiType, UINT* dpiX, UINT *dpiY )
|
||||
! GetDpiForShellUIComponent
|
||||
! GetFeatureEnabledState
|
||||
! GetFeatureVariant
|
||||
! GetProcessDpiAwareness
|
||||
! GetProcessReference
|
||||
! GetScaleFactorForDevice
|
||||
! GetScaleFactorForMonitor
|
||||
! IsOS
|
||||
! IsProcessInIsolatedContainer
|
||||
! IStream_Copy
|
||||
! IStream_Read
|
||||
! IStream_ReadStr
|
||||
! IStream_Reset
|
||||
! IStream_Size
|
||||
! IStream_Write
|
||||
! IStream_WriteStr
|
||||
! IUnknown_AtomicRelease
|
||||
! IUnknown_GetSite
|
||||
! IUnknown_QueryService
|
||||
! IUnknown_Set
|
||||
! IUnknown_SetSite
|
||||
! RecordFeatureError
|
||||
! RecordFeatureUsage
|
||||
! RegisterScaleChangeEvent
|
||||
! RegisterScaleChangeNotifications
|
||||
! RevokeScaleChangeNotifications
|
||||
! SetCurrentProcessExplicitAppUserModelID
|
||||
! SetProcessDpiAwareness
|
||||
! SetProcessReference
|
||||
! SHAnsiToAnsi
|
||||
! SHAnsiToUnicode
|
||||
! SHCopyKeyA
|
||||
! SHCopyKeyW
|
||||
! SHCreateMemStream
|
||||
! SHCreateStreamOnFileA
|
||||
! SHCreateStreamOnFileEx
|
||||
! SHCreateStreamOnFileW
|
||||
! SHCreateThread
|
||||
! SHCreateThreadRef
|
||||
! SHCreateThreadWithHandle
|
||||
! SHDeleteEmptyKeyA
|
||||
! SHDeleteEmptyKeyW
|
||||
! SHDeleteKeyA
|
||||
! SHDeleteKeyW
|
||||
! SHDeleteValueA
|
||||
! SHDeleteValueW
|
||||
! SHEnumKeyExA
|
||||
! SHEnumKeyExW
|
||||
! SHEnumValueA
|
||||
! SHEnumValueW
|
||||
! SHGetThreadRef
|
||||
! SHGetValueA
|
||||
! SHGetValueW
|
||||
! SHOpenRegStream2A
|
||||
! SHOpenRegStream2W
|
||||
! SHOpenRegStreamA
|
||||
! SHOpenRegStreamW
|
||||
! SHQueryInfoKeyA
|
||||
! SHQueryInfoKeyW
|
||||
! SHQueryValueExA
|
||||
! SHQueryValueExW
|
||||
! SHRegDuplicateHKey
|
||||
! SHRegGetIntW
|
||||
! SHRegGetPathA
|
||||
! SHRegGetPathW
|
||||
! SHRegGetValueA
|
||||
! SHRegGetValueFromHKCUHKLM
|
||||
! SHRegGetValueW
|
||||
! SHRegSetPathA
|
||||
! SHRegSetPathW
|
||||
! SHReleaseThreadRef
|
||||
! SHSetThreadRef
|
||||
! SHSetValueA
|
||||
! SHSetValueW
|
||||
! SHStrDupA
|
||||
! SHStrDupW
|
||||
! SHUnicodeToAnsi
|
||||
! SHUnicodeToUnicode
|
||||
! SubscribeFeatureStateChangeNotification
|
||||
! UnregisterScaleChangeEvent
|
||||
! UnsubscribeFeatureStateChangeNotification
|
|
@ -0,0 +1 @@
|
|||
bindings
|
|
@ -1788,7 +1788,7 @@ ALIAS: MessageBoxEx MessageBoxExW
|
|||
|
||||
! FUNCTION: ModifyMenuA
|
||||
! FUNCTION: ModifyMenuW
|
||||
! FUNCTION: MonitorFromPoint
|
||||
FUNCTION: HMONITOR MonitorFromPoint ( POINT pt, DWORD dwFlags )
|
||||
! FUNCTION: MonitorFromRect
|
||||
FUNCTION: HMONITOR MonitorFromWindow ( HWND hWnd, DWORD dwFlags )
|
||||
! FUNCTION: mouse_event
|
||||
|
|
|
@ -20,6 +20,7 @@ CONSTANT: MAX_UNICODE_PATH 32768
|
|||
{ "gl" "opengl32.dll" stdcall }
|
||||
{ "glu" "glu32.dll" stdcall }
|
||||
{ "ole32" "ole32.dll" stdcall }
|
||||
{ "shcore" "shcore.dll" stdcall }
|
||||
{ "usp10" "usp10.dll" stdcall }
|
||||
{ "psapi" "psapi.dll" stdcall }
|
||||
{ "winmm" "winmm.dll" stdcall }
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity type="win32"
|
||||
name="factor"
|
||||
version="0.9.8.0"
|
||||
/>
|
||||
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<windowsSettings>
|
||||
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">True/PM</dpiAware>
|
||||
</windowsSettings>
|
||||
</application>
|
||||
</assembly>
|
|
@ -3,7 +3,10 @@ namespace factor {
|
|||
#define CALLSTACK_BOTTOM(ctx) \
|
||||
(ctx->callstack_seg->end - sizeof(cell) * 5)
|
||||
|
||||
inline static void flush_icache(cell start, cell len) {}
|
||||
inline static void flush_icache(cell start, cell len) {
|
||||
(void)start;
|
||||
(void)len;
|
||||
}
|
||||
|
||||
// In the instruction sequence:
|
||||
|
||||
|
|
Loading…
Reference in New Issue