diff --git a/kernel/trunk/const.inc b/kernel/trunk/const.inc index 7262887139..0f8b2feae7 100644 --- a/kernel/trunk/const.inc +++ b/kernel/trunk/const.inc @@ -516,7 +516,7 @@ struct APPDATA draw_bgr_x dd ? ;+116 draw_bgr_y dd ? ;+120 state db ? ;+124 ; R thread state - db ? ;+125 + wnd_number db ? ;+125 ; R dw ? ;+126 wnd_shape dd ? ;+128 wnd_shape_scale dd ? ;+132 diff --git a/kernel/trunk/core/taskman.inc b/kernel/trunk/core/taskman.inc index 2b7b5b1105..7f9b225ab8 100644 --- a/kernel/trunk/core/taskman.inc +++ b/kernel/trunk/core/taskman.inc @@ -975,8 +975,9 @@ proc set_app_params stdcall,slot:dword, params:dword, flags:dword ;mov dword [TASK_TABLE+ebx+TASKDATA.mem_start], 0 mov dword [ebx+SLOT_BASE+APPDATA.mem_start], 0 - mov ebx, [slot] - mov eax, ebx + mov eax, [slot] + mov [ebx+SLOT_BASE+APPDATA.wnd_number], al + mov ebx, eax shl ebx, 5 lea ecx, [draw_data+ebx];ecx - pointer to draw data @@ -984,7 +985,7 @@ proc set_app_params stdcall,slot:dword, params:dword, flags:dword mov [ebx+window_data+WDATA.fl_wstate], WSTATE_NORMAL mov [ebx+window_data+WDATA.fl_redraw], 1 add ebx, TASK_TABLE ;ebx - pointer to information about process - mov [ebx+TASKDATA.wnd_number], al;set window number on screen = process slot + ;mov [ebx+TASKDATA.wnd_number], al;set window number on screen = process slot mov [ebx+TASKDATA.event_mask], dword 1+2+4;set default event flags (see 40 function) diff --git a/kernel/trunk/kernel.asm b/kernel/trunk/kernel.asm index fa48e72934..e86cd6aab6 100644 --- a/kernel/trunk/kernel.asm +++ b/kernel/trunk/kernel.asm @@ -1181,10 +1181,11 @@ proc setup_os_slot lea ecx, [sys_proc+PROC.thr_list] list_add_tail ebx, ecx + mov [edx+APPDATA.wnd_number], dh mov eax, edx shr eax, 3 add eax, TASK_TABLE - (SLOT_BASE shr 3) - mov [eax+TASKDATA.wnd_number], dh + ;mov [eax+TASKDATA.wnd_number], dh mov byte [eax+TASKDATA.pid], dh ret