From f1f3efb4bad27e3444b3ff84f72e1d52f16a26ca Mon Sep 17 00:00:00 2001 From: "Mihail Semenyako (mike.dld)" Date: Sat, 11 Mar 2006 01:15:32 +0000 Subject: [PATCH] Fix to saving window position code git-svn-id: svn://kolibrios.org@57 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/trunk/gui/window.inc | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/kernel/trunk/gui/window.inc b/kernel/trunk/gui/window.inc index 2b33288326..38c12cfbce 100644 --- a/kernel/trunk/gui/window.inc +++ b/kernel/trunk/gui/window.inc @@ -1323,14 +1323,14 @@ checkwindows: cmp eax,[edi+0] jb nnepx sub eax,[edi+0] - cmp eax,[edx+0x90+8] + cmp eax,32 ; [edx+0x90+8] jge nnepx2 - mov eax,[edx+0x90+8] + mov eax,32 ; [edx+0x90+8] nnepx2: mov [npxe],eax nnepx: - call get_titlebar_height + call get_rolledup_height mov ebx,eax movzx eax,word [0xfb0c] cmp eax,[edi+4] @@ -1385,11 +1385,14 @@ checkwindows: ; push esi edi ecx mov esi,edi - sub edi,window_data + mov ecx,2 + test [edi+WDATA.fl_wstate],WSTATE_ROLLEDUP or WSTATE_MAXIMIZED + jnz @f + add ecx,2 + @@: sub edi,window_data shr edi,5 shl edi,8 add edi,0x80000+0x90 - mov ecx,4 cld rep movsd pop ecx edi esi