Subversion Repositories Kolibri OS

Rev

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

Rev 1055 Rev 1059
Line 3... Line 3...
3
;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;;
4
;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa      ;;
4
;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa      ;;
5
;; Distributed under terms of the GNU General Public License    ;;
5
;; Distributed under terms of the GNU General Public License    ;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 7... Line 7...
7
 
7
 
Line 8... Line 8...
8
$Revision: 1055 $
8
$Revision: 1059 $
9
 
9
 
10
uglobal
10
uglobal
11
align 4
11
align 4
Line 98... Line 98...
98
;   eax - óêàçàòåëü íà event, ÊÎÒÎÐÛÉ âñòàâëÿåì
98
;   eax - óêàçàòåëü íà event, ÊÎÒÎÐÛÉ âñòàâëÿåì
99
;   ebx - óêàçàòåëü íà event, ÏÎÑËÅ êîòîðîãî âñòàâëÿåì
99
;   ebx - óêàçàòåëü íà event, ÏÎÑËÅ êîòîðîãî âñòàâëÿåì
100
;scratched: ebx,ecx
100
;scratched: ebx,ecx
101
        mov     ecx,eax              ; ecx=eax=Self,      ebx=NewLeft
101
        mov     ecx,eax              ; ecx=eax=Self,      ebx=NewLeft
102
        xchg    ecx,[ebx+EVENT.fd]   ; NewLeft.fd=Self,   ecx=NewRight
102
        xchg    ecx,[ebx+EVENT.fd]   ; NewLeft.fd=Self,   ecx=NewRight
-
 
103
        cmp     eax,ecx              ; ñòîï, ñåáå äóìàþ...
-
 
104
        je      .break               ; - à íå äóðàê ëè ÿ?
103
        mov     [ecx+EVENT.bk],eax   ; NewRight.bk=Self
105
        mov     [ecx+EVENT.bk],eax   ; NewRight.bk=Self
104
        xchg    ebx,[eax+EVENT.bk]   ; Self.bk=NewLeft,   ebx=OldLeft
106
        xchg    ebx,[eax+EVENT.bk]   ; Self.bk=NewLeft,   ebx=OldLeft
105
        xchg    ecx,[eax+EVENT.fd]   ; Self.fd=NewRight,  ecx=OldRight
107
        xchg    ecx,[eax+EVENT.fd]   ; Self.fd=NewRight,  ecx=OldRight
106
        mov     [ebx+EVENT.fd],ecx   ; OldLeft.fd=OldRight
108
        mov     [ebx+EVENT.fd],ecx   ; OldLeft.fd=OldRight
107
        mov     [ecx+EVENT.bk],ebx   ; OldRight.bk=OldLeft
109
        mov     [ecx+EVENT.bk],ebx   ; OldRight.bk=OldLeft