328,15 → 328,19 |
cmp ebx, -1 |
jne @f |
mov ebx, [edi + WDATA.box.left] |
and bl, 0xFC |
@@: cmp ecx, -1 |
jne @f |
mov ecx, [edi + WDATA.box.top] |
and cl, 0xFE |
@@: cmp edx, -1 |
jne @f |
mov edx, [edi + WDATA.box.width] |
and dl, 0xFC |
@@: cmp esi, -1 |
jne @f |
mov esi, [edi + WDATA.box.height] |
and esi, 0xFFFFFFFE |
|
@@: push esi edx ecx ebx |
mov eax, esp |
344,14 → 348,6 |
call window._.set_window_box |
add esp, BOX.sizeof |
|
; NOTE: do we really need this? to be reworked |
; mov byte[DONT_DRAW_MOUSE], 0 ; mouse pointer |
; mov byte[MOUSE_BACKGROUND], 0 ; no mouse under |
; mov byte[MOUSE_DOWN], 0 ; react to mouse up/down |
|
; NOTE: do we really need this? to be reworked |
; call [draw_pointer] |
|
.exit: |
ret |
|
519,8 → 515,10 |
mov eax, [edi + WDATA.box.width] |
sub eax, ebx |
jle @f |
and bl, 0xFC ; <<<<<<< |
mov [edi + WDATA.box.width], ebx |
@@: sub ebx, [edi + WDATA.box.width] |
and bl, 0xFC ; <<<<<<< |
mov [edi + WDATA.box.left], ebx |
|
.fix_vertical: |
532,8 → 530,10 |
mov eax, [edi + WDATA.box.height] |
sub eax, ebx |
jle @f |
and bl, 0xFE ; <<<<<<< |
mov [edi + WDATA.box.height], ebx |
@@: sub ebx, [edi + WDATA.box.height] |
and bl, 0xFE ; <<<<<<< |
mov [edi + WDATA.box.top], ebx |
jmp .fix_client_box |
|
555,7 → 555,8 |
call window._.set_window_clientbox |
|
add edi, WDATA.sizeof |
loop .next_window |
dec ecx |
jne .next_window ; <<<<<<<<<<< |
|
.exit: |
ret |
1454,7 → 1455,9 |
movzx eax, cx |
mov [edi + WDATA.box.height], eax |
sar ebx, 16 |
and bl, 0xFC ; <<<<<<<< |
sar ecx, 16 |
and cl, 0xFE ; <<<<<<<< |
mov [edi + WDATA.box.left], ebx |
mov [edi + WDATA.box.top], ecx |
|
1673,10 → 1676,11 |
|
; get WinMap start |
push esi |
mov edi, [Screen_Max_X] |
inc edi |
mov edi, [_WinMapWidth] |
mov esi, edi |
imul edi, ebx |
shr eax, 1 |
shr eax, 1 |
add edi, eax |
add edi, [_WinMapAddress] |
pop eax |
1715,12 → 1719,13 |
|
; get WinMap start -> ebp |
push eax |
mov eax, [Screen_Max_X] ; screen_sx |
inc eax |
mov eax, [_WinMapWidth] ; <<<< |
imul eax, ebx |
add eax, [esp] |
add eax, [_WinMapAddress] |
mov ebp, eax |
mov ebp, [esp] |
shr ebp, 1 |
shr ebp, 1 |
add ebp, eax |
add ebp, [_WinMapAddress] |
|
mov edi, [edi + APPDATA.wnd_shape] |
pop eax |
2085,4 → 2090,4 |
ret |
|
diff16 "window code end",0,$ |
diff16 "window.inc size",syscall_draw_window,$ |
diff10 "window.inc size",syscall_draw_window,$ |