diff --git a/kernel/trunk/docs/sysfuncr.txt b/kernel/trunk/docs/sysfuncr.txt index 0366255c60..b1bc7458d7 100644 --- a/kernel/trunk/docs/sysfuncr.txt +++ b/kernel/trunk/docs/sysfuncr.txt @@ -1768,6 +1768,9 @@ db 'Kolibri',0 * eax ᮤন ଠ : * 0 ⠭ = * 1 ⠭ = ࠢ + * 2 ⠭ = । + * 3 ⠭ = 4- + * 4 ⠭ = 5- * 稥 襭 ------------------ 㭪 4 - 㧨 ------------------- @@ -1819,6 +1822,17 @@ db 'Kolibri',0 * ᫨ 㤠 ⨢ (⠭ 㭪樥 5) , ⠭ 㬮砭 (⠭⭠ ५). +------------------- 㭪 7 - ப⪨ -------------------- +ࠬ: + * eax = 37 - 㭪樨 + * ebx = 7 - 㭪樨 +頥 祭: + * eax = horizontal_offset*65536 + vertical_offset +砭: + * 㯭 ⮫쪮 ⨢ + * ᫥ ⥭ 祭 + * ᮤঠ 祭 + ====================================================================== ================== 㭪 38 - ᮢ १. ================== ====================================================================== diff --git a/kernel/trunk/docs/sysfuncs.txt b/kernel/trunk/docs/sysfuncs.txt index 30ad511d91..92fc885fd0 100644 --- a/kernel/trunk/docs/sysfuncs.txt +++ b/kernel/trunk/docs/sysfuncs.txt @@ -674,7 +674,7 @@ Parameters: Returned value: * eax = 0 - success * else eax = error code of the file system -: +: * All folders in the given path must exist, otherwise function returns value 5, "file not found". @@ -1414,7 +1414,7 @@ Parameters: Returned value: * eax = 0 - success * eax = 1 - CD base is not defined -: +: * Previously CD base port must be defined by call to subfunction 3 of function 21. @@ -1744,6 +1744,9 @@ Returned value: * eax contains information on the pressed mouse buttons: * bit 0 is set = left button is pressed * bit 1 is set = right button is pressed + * bit 2 is set = middle button is pressed + * bit 3 is set = 4th button is pressed + * bit 4 is set = 5th button is pressed * other bits are cleared -------------------- Subfunction 4 - load cursor --------------------- @@ -1794,6 +1797,17 @@ Remarks: * If the active cursor (set by subfunction 5) is deleted, the system restores the default cursor (standard arrow). +------------------- Subfunction 7 - get scroll data -------------------- +Parameters: + * eax = 37 - function number + * ebx = 7 - subfunction number +Returned value: + * eax = horizontal_offset*65536 + vertical_offset +Remarks: + * Scroll data is available for active window only + * Values are zeroized after reading + * Values ara signed + ====================================================================== ====================== Function 38 - draw line. ====================== ====================================================================== @@ -2028,8 +2042,8 @@ Parameters: * bh = 0 - display in decimal number system * bh = 1 - display in hexadecimal system * bh = 2 - display in binary system - * 16-21 = how many digits to display - * 22-31 reserved and must be set to 0 + * v 16-21 = how many digits to display + * v 22-31 reserved and must be set to 0 * ecx = number (if bl=0) or pointer (if bl=1) * edx = [coordinate on axis x]*65536 + [coordinate on axis y] * esi = 0xX0RRGGBB: @@ -3560,7 +3574,7 @@ Parameters: * esi:edi = high:low dword Returned value: * ebx:eax = copy of esi:edi -: +: * If ecx contains nonexistent or not implemented for this processor MSR, processor will generate an exception in the kernel, which will kill the thread. diff --git a/kernel/trunk/drivers/ps2m_irqh.inc b/kernel/trunk/drivers/ps2m_irqh.inc index 511822ebbb..ee6cf3eede 100644 --- a/kernel/trunk/drivers/ps2m_irqh.inc +++ b/kernel/trunk/drivers/ps2m_irqh.inc @@ -1,11 +1,11 @@ ;************************************** -;* PS/2 * +;* IRQ HANDLER FOR PS/2 MOUSE * ;************************************** proc irq_handler - call Wait8042BufferEmpty ; - in al,0x60 ; - + call Wait8042BufferEmpty ;clear buffer + in al,0x60 ;get scan-code cmp [mouse_byte],0 je .byte1 @@ -18,8 +18,8 @@ proc irq_handler jmp .error .byte1: - test al,1000b ; ? - jz .error ; + test al,1000b ;first byte? + jz .error mov [first_byte],al inc [mouse_byte] jmp .exit @@ -66,7 +66,7 @@ proc irq_handler mov [ZMoving],eax .xy_moving: - mov ah,0 ; AH + mov ah,0 mov al,[first_byte] test al,10000b jz @f @@ -77,7 +77,7 @@ proc irq_handler cwd mov [XMoving],eax - mov ah,0 ; AH + mov ah,0 mov al,[first_byte] test al,100000b jz @f @@ -103,10 +103,10 @@ endp ;*********************************************** -;* I8042 * -;* : * -;* ZF - , * -;* ZF - -. * +;* Waiting for clearing I8042 buffer * +;* Retutned state: * +;* ZF is set - good ending, * +;* ZF is cleared - time-out error. * ;*********************************************** Wait8042BufferEmpty: push ecx @@ -117,4 +117,4 @@ Wait8042BufferEmpty: loopnz @b pop ecx - ret ; + ret diff --git a/kernel/trunk/drivers/ps2mouse.asm b/kernel/trunk/drivers/ps2mouse.asm index b8805889fb..f4bd50e4ee 100644 --- a/kernel/trunk/drivers/ps2mouse.asm +++ b/kernel/trunk/drivers/ps2mouse.asm @@ -1,10 +1,3 @@ -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -;; ;; -;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;; -;; Distributed under terms of the GNU General Public License ;; -;; ;; -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; - format MS COFF include 'proc32.inc'