Subversion Repositories Kolibri OS

Rev

Rev 9614 | Rev 9709 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 9614 Rev 9692
Line 3... Line 3...
3
;; Copyright (C) KolibriOS team 2004-2021. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2021. All rights reserved. ;;
4
;;  Distributed under terms of the GNU General Public License.  ;;
4
;;  Distributed under terms of the GNU General Public License.  ;;
5
;;                                                              ;;
5
;;                                                              ;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 7... Line 7...
7
 
7
 
Line 8... Line 8...
8
$Revision: 9614 $
8
$Revision: 9692 $
Line 9... Line 9...
9
 
9
 
Line 474... Line 474...
474
 
474
 
475
align 4
475
align 4
476
get_pid:
476
get_pid:
477
        mov     eax, [current_slot]
477
        mov     eax, [current_slot]
478
        mov     eax, [eax+APPDATA.tid]
-
 
479
        mov     eax, [TASK_BASE]             ; delete
-
 
480
        mov     eax, [eax+TASKDATA.pid]      ;
478
        mov     eax, [eax+APPDATA.tid]
Line 481... Line 479...
481
        ret
479
        ret
482
 
480
 
483
pid_to_slot:
481
pid_to_slot:
Line 500... Line 498...
500
.loop:
498
.loop:
501
;ecx = offset of current process info entry
499
;ecx = offset of current process info entry
502
;ebx = maximum permitted offset
500
;ebx = maximum permitted offset
503
        cmp     [TASK_TABLE+ecx+TASKDATA.state], TSTATE_FREE
501
        cmp     [TASK_TABLE+ecx+TASKDATA.state], TSTATE_FREE
504
        jz      .endloop ;skip empty slots
502
        jz      .endloop ;skip empty slots
505
        cmp     [TASK_TABLE+ecx+TASKDATA.pid], eax;check PID
-
 
506
        jz      .pid_found
-
 
507
        ;cmp     [ecx+SLOT_BASE+APPDATA.state], TSTATE_FREE
503
        ;cmp     [ecx+SLOT_BASE+APPDATA.state], TSTATE_FREE
508
        ;jz      .endloop ;skip empty slots
504
        ;jz      .endloop ;skip empty slots
509
        ;cmp     [ecx+SLOT_BASE+APPDATA.pid], eax;check PID
505
        cmp     [ecx*8 + SLOT_BASE + APPDATA.tid], eax;check PID
510
        ;jz      .pid_found
506
        jz      .pid_found
511
.endloop:
507
.endloop:
512
        add     ecx, sizeof.TASKDATA
508
        add     ecx, sizeof.TASKDATA
513
        ;add     ecx, sizeof.APPDATA
509
        ;add     ecx, sizeof.APPDATA
514
        cmp     ecx, ebx
510
        cmp     ecx, ebx
515
        jle     .loop
511
        jle     .loop
Line 995... Line 991...
995
        lea     ecx, [draw_data+ebx];ecx - pointer to draw data
991
        lea     ecx, [draw_data+ebx];ecx - pointer to draw data
Line 996... Line 992...
996
 
992
 
997
; set window state to 'normal' (non-minimized/maximized/rolled-up) state
993
; set window state to 'normal' (non-minimized/maximized/rolled-up) state
998
        mov     [ebx+window_data+WDATA.fl_wstate], WSTATE_NORMAL
994
        mov     [ebx+window_data+WDATA.fl_wstate], WSTATE_NORMAL
999
        mov     [ebx+window_data+WDATA.fl_redraw], 1
-
 
1000
        add     ebx, TASK_TABLE     ;ebx - pointer to information about process
-
 
1001
 
-
 
1002
        mov     eax, [process_number]                     ; delete
-
 
Line 1003... Line 995...
1003
        mov     [ebx+TASKDATA.pid], eax    ;set PID       ;
995
        mov     [ebx+window_data+WDATA.fl_redraw], 1
1004
 
996
 
1005
;set draw data to full screen
997
;set draw data to full screen
1006
        xor     eax, eax
998
        xor     eax, eax