Fixed several structure errors in windows, and one in x11.

This commit is contained in:
Brad Nelson
2024-11-28 17:50:36 -08:00
parent 360417dd53
commit db30147131
4 changed files with 10 additions and 12 deletions

View File

@ -83,7 +83,7 @@ StructureNotifyMask or constant EVENT-MASK
xevent [ xany ] ->type sl@ to xevent-type
Expose xevent-type = if
[ xexposure ]
xevent ->count @ 0= if
xevent ->count sl@ 0= if
EXPOSED to event
exit
then

View File

@ -35,12 +35,12 @@ cell allocate throw to backbuffer
backbuffer w h * 4* resize throw to backbuffer
backbuffer w h * 4* 255 fill
binfo BITMAPINFO erase
BITMAPINFOHEADER binfo ->bmiHeader ->biSize !
w binfo ->bmiHeader ->biWidth !
h negate binfo ->bmiHeader ->biHeight !
1 binfo ->bmiHeader ->biPlanes !
32 binfo ->bmiHeader ->biBitCount !
BI_RGB binfo ->bmiHeader ->biCompression !
BITMAPINFOHEADER binfo ->bmiHeader ->biSize l!
w binfo ->bmiHeader ->biWidth l!
h negate binfo ->bmiHeader ->biHeight l!
1 binfo ->bmiHeader ->biPlanes w!
32 binfo ->bmiHeader ->biBitCount w!
BI_RGB binfo ->bmiHeader ->biCompression l!
RESIZED to event
;
@ -161,7 +161,7 @@ also windows
event FINISHED = if exit then
IDLE to event
msgbuf NULL 0 0 PM_REMOVE PeekMessageA if
WM_QUIT msgbuf ->message @ = if
WM_QUIT msgbuf ->message ul@ = if
FINISHED to event
exit
then

View File

@ -33,10 +33,7 @@ create ps PAINTSTRUCT allot
0 255 0 RGB CreateSolidBrush constant green
create side RECT allot
0 side ->left l!
0 side ->top l!
200 side ->right l!
100 side ->bottom l!
side 0 0 200 100 SetRect
: MyWindowProc { hwnd msg w l }
WM_DESTROY msg = if

View File

@ -104,6 +104,7 @@ struct RECT
i32 field ->top
i32 field ->right
i32 field ->bottom
z" SetRect" 5 User32 SetRect
z" GetMessageA" 4 User32 GetMessageA
z" PeekMessageA" 5 User32 PeekMessageA