Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 480 → Rev 479

/kernel/trunk/hid/m_ps2.inc
66,13 → 66,15
; Âû÷èñëèòü íîâîå çíà÷åíèå êîîðäèíàòû
; êóðñîðà ïî X
add AX,[MOUSE_X] ;[XCoordinate]
jns @@M1
xor eax, eax
cmp AX,0
jge @@M1
mov AX,0
jmp @@M2
@@M1:
cmp AX,[ScreenWidth] ;ScreenLength
jl @@M2
mov AX,[ScreenWidth] ;ScreenLength-1
dec ax
@@M2:
mov [MOUSE_X],AX ;[XCoordinate]
 
92,13 → 94,15
; ïðîòèâîïîëîæíî ýêðàííîé)
neg AX
add AX,[MOUSE_Y] ;[YCoordinate]
jns @@M4
xor eax, eax
cmp AX,0
jge @@M4
mov AX,0
jmp @@M5
@@M4:
cmp AX,[ScreenHeight] ;ScreenHeigth
jl @@M5
mov AX,[ScreenHeight] ;ScreenHeigth-1
dec ax
@@M5:
mov [MOUSE_Y],AX ;[YCoordinate]