Subversion Repositories Kolibri OS

Rev

Rev 1505 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1505 Rev 1689
Line 345... Line 345...
345
    * +66 = +0x42: dword: height of the client area
345
    * +66 = +0x42: dword: height of the client area
346
    * +70 = +0x46: byte: state of the window - bitfield
346
    * +70 = +0x46: byte: state of the window - bitfield
347
      * bit 0 (mask 1): window is maximized
347
      * bit 0 (mask 1): window is maximized
348
      * bit 1 (mask 2): window is minimized to panel
348
      * bit 1 (mask 2): window is minimized to panel
349
      * bit 2 (mask 4): window is rolled up
349
      * bit 2 (mask 4): window is rolled up
-
 
350
    * +71 = +0x47: dword: event mask
350
Remarks:
351
Remarks:
351
  * Slots are numbered starting from 1.
352
  * Slots are numbered starting from 1.
352
  * Returned value is not a total number of threads, because there
353
  * Returned value is not a total number of threads, because there
353
    can be free slots.
354
    can be free slots.
354
  * When process is starting, system automatically creates
355
  * When process is starting, system automatically creates
Line 842... Line 843...
842
    the information will be placed
843
    the information will be placed
843
Returned value:
844
Returned value:
844
  * function does not return value
845
  * function does not return value
845
Structure of the buffer:
846
Structure of the buffer:
846
db a,b,c,d for version a.b.c.d
847
db a,b,c,d for version a.b.c.d
847
db UID_xxx: one of UID_NONE=0, UID_MENUET=1, UID_KOLIBRI=2
-
 
-
 
848
db 0
848
dd REV - kernel SVN revision number
849
dd REV - kernel SVN revision number
849
For Kolibri 0.7.1.0 kernel:
850
For Kolibri 0.7.7.0 kernel:
850
db 0,7,0,0
851
db 0,7,7,0
851
db 2
852
db 2
852
dd 638
853
dd 1657
Line 853... Line 854...
853
 
854
 
854
======================================================================
855
======================================================================
855
======= Function 18, subfunction 14 - wait for screen retrace. =======
856
======= Function 18, subfunction 14 - wait for screen retrace. =======
856
======================================================================
857
======================================================================
Line 1656... Line 1657...
1656
Returned value:
1657
Returned value:
1657
  * eax = size of the current folder's name (including terminating 0)
1658
  * eax = size of the current folder's name (including terminating 0)
1658
Remarks:
1659
Remarks:
1659
  * If the buffer is too small to hold all data, only first (edx-1)
1660
  * If the buffer is too small to hold all data, only first (edx-1)
1660
    bytes are copied and than terminating 0 is inserted.
1661
    bytes are copied and than terminating 0 is inserted.
1661
 
-
 
1662
======================================================================
-
 
1663
=============== Function 32 - delete file from ramdisk. ==============
-
 
1664
======================================================================
-
 
1665
Parameters:
-
 
1666
  * eax = 32 - function number
-
 
1667
  * ebx = pointer to the filename
-
 
1668
Returned value:
-
 
1669
  * eax = 0 - success; otherwise file system error code
-
 
1670
Remarks:
-
 
1671
  * This function is obsolete; function 58 allows to fulfill
-
 
1672
    the same operations with the extended possibilities.
-
 
1673
  * The current implementation returns only values 0(success) and
-
 
1674
    5(file not found).
-
 
1675
  * The filename must be either in the format 8+3 characters
1662
  * By default, current folder for the thread is "/rd/1".
1676
    (first 8 characters - name itself, last 3 - extension,
-
 
1677
    the short names and extensions are supplemented with spaces),
-
 
1678
    or in the format 8.3 characters "FILE.EXT"/"FILE.EX "
-
 
1679
    (name no more than 8 characters, dot, extension 3 characters
-
 
1680
    supplemented if necessary by spaces).
-
 
1681
    The filename must be written with capital letters. The terminating
-
 
1682
    character with code 0 is not necessary (not ASCIIZ-string).
-
 
1683
  * This function does not support folders on the ramdisk.
-
 
1684
 
-
 
1685
======================================================================
-
 
1686
================ Function 33 - write file to ramdisk. ================
-
 
1687
======================================================================
-
 
1688
Parameters:
-
 
1689
  * eax = 33 - function number
-
 
1690
  * ebx = pointer to the filename
-
 
1691
  * ecx = pointer to data for writing
-
 
1692
  * edx = number of bytes for writing
-
 
1693
  * should be set esi=0
-
 
1694
Returned value:
-
 
1695
  * eax = 0 - success, otherwise file system error code
-
 
1696
Remarks:
-
 
1697
  * This function is obsolete; function 70 allows to fulfil
-
 
1698
    the same operations with extended possibilities.
-
 
1699
  * If esi contains non-zero value and selected file already exists,
-
 
1700
    one more file with the same name will be created.
1663
  * At process/thread creation the current folder will be inherited 
1701
  * Otherwise file will be overwritten.
-
 
1702
  * The filename must be either in the format 8+3 characters
-
 
1703
    (first 8 characters - name itself, last 3 - extension,
-
 
1704
    the short names and extensions are supplemented with spaces),
-
 
1705
    or in the format 8.3 characters "FILE.EXT"/"FILE.EX "
-
 
1706
    (name no more than 8 characters, dot, extension 3 characters
-
 
1707
    supplemented if necessary by spaces).
-
 
1708
    The filename must be written with capital letters. The terminating
-
 
1709
    character with code 0 is not necessary (not ASCIIZ-string).
-
 
1710
  * This function does not support folders on the ramdisk.
-
 
Line 1711... Line 1664...
1711
 
1664
 
1712
======================================================================
1665
======================================================================
1713
======= Function 35 - read the color of a pixel on the screen. =======
1666
======= Function 35 - read the color of a pixel on the screen. =======
1714
======================================================================
1667
======================================================================
Line 3419... Line 3372...
3419
======================================================================
3372
======================================================================
3420
================== Function 66 - work with keyboard. =================
3373
================== Function 66 - work with keyboard. =================
3421
======================================================================
3374
======================================================================
3422
The input mode influences results of reading keys by function 2.
3375
The input mode influences results of reading keys by function 2.
3423
When a program loads, ASCII input mode is set for it.
3376
When a program loads, ASCII input mode is set for it.
3424
If subfunction is not support then eax=-1.
-
 
Line 3425... Line 3377...
3425
 
3377
 
3426
-------------- Subfunction 1 - set keyboard input mode. --------------
3378
-------------- Subfunction 1 - set keyboard input mode. --------------
3427
Parameters:
3379
Parameters:
3428
  * eax = 66 - function number
3380
  * eax = 66 - function number
Line 3771... Line 3723...
3771
    with subfunction 12. Otherwise the block at edx
3723
    with subfunction 12. Otherwise the block at edx
3772
    must be allocated earlier with subfunction 12 or this subfunction.
3724
    must be allocated earlier with subfunction 12 or this subfunction.
3773
  * If ecx=0, the function frees memory block at edx and returns 0.
3725
  * If ecx=0, the function frees memory block at edx and returns 0.
3774
  * The contents of the block are unchanged up to the shorter of
3726
  * The contents of the block are unchanged up to the shorter of
3775
    the new and old sizes.
3727
    the new and old sizes.
-
 
3728
======================================================================
-
 
3729
======== Function 68, subfunction 22 - open named memory area. =======
-
 
3730
======================================================================
-
 
3731
Parameters:
-
 
3732
  * eax = 68 - function number
-
 
3733
  * ebx = 22 - subfunction number
-
 
3734
  * ecx = area name. Maximum of 31 characters with terminating zero
-
 
3735
  * edx = area size in bytes for SHM_CREATE and SHM_OPEN_ALWAYS
-
 
3736
  * esi = flags for open and access:
-
 
3737
    * SHM_OPEN        = 0x00 - open existing memory area. If an area
-
 
3738
                          with such name does not exist, the function
-
 
3739
                          will return error code 5.
-
 
3740
    * SHM_OPEN_ALWAYS = 0x04 - open existing or create new
-
 
3741
                          memory area.
-
 
3742
    * SHM_CREATE      = 0x08 - create new memory area. If an area
-
 
3743
                          with such name already exists, the function
-
 
3744
                          will return error code 10.
-
 
3745
    * SHM_READ        = 0x00 - only read access
-
 
3746
    * SHM_WRITE       = 0x01 - read and write access
-
 
3747
Returned value:
-
 
3748
  * eax = pointer to memory area, 0 if error has occured
-
 
3749
  * if new area is created (SHM_CREATE or SHM_OPEN_ALWAYS):
-
 
3750
    edx = 0 - success, otherwise - error code
-
 
3751
  * if existing area is opened (SHM_OPEN or SHM_OPEN_ALWAYS):
-
 
3752
    edx = error code (if eax=0) or area size in bytes
-
 
3753
Error codes:
-
 
3754
  * E_NOTFOUND = 5
-
 
3755
  * E_ACCESS = 10
-
 
3756
  * E_NOMEM = 30
-
 
3757
  * E_PARAM = 33
-
 
3758
Remarks:
-
 
3759
  * Before this call one must initialize process heap by call to
-
 
3760
    subfunction 11.
-
 
3761
  * If a new area is created, access flags set maximal rights
-
 
3762
    for other processes. An attempt from other process to open
-
 
3763
    with denied rights will fail with error code E_ACCESS.
-
 
3764
  * The process which has created an area always has write access.
-
 
3765
 
-
 
3766
======================================================================
-
 
3767
======= Function 68, subfunction 23 - close named memory area. =======
-
 
3768
======================================================================
-
 
3769
Parameters:
-
 
3770
  * eax = 68 - function number
-
 
3771
  * ebx = 23 - subfunction number
-
 
3772
  * ecx = area name. Maximum of 31 characters with terminating zero
-
 
3773
Returned value:
-
 
3774
  * eax destroyed
-
 
3775
Remarks:
-
 
3776
  * A memory area is physically freed (with deleting all data and
-
 
3777
    freeing physical memory), when all threads which have opened
-
 
3778
    this area will close it.
-
 
3779
  * When thread is terminating, all opened by it areas are closed.
Line 3776... Line 3780...
3776
 
3780
 
3777
======================================================================
3781
======================================================================
3778
====== Function 68, subfunction 24 - set new exceptions handler ======
3782
====== Function 68, subfunction 24 - set new exceptions handler ======
3779
======================================================================
3783
======================================================================
Line 3811... Line 3815...
3811
  * ebx = 25 - subfunction number
3815
  * ebx = 25 - subfunction number
3812
  * ecx = signal number
3816
  * ecx = signal number
3813
  * edx = value of activity (0/1)
3817
  * edx = value of activity (0/1)
3814
Returned value:
3818
Returned value:
3815
  * eax = value of old activity for this signal (0/1)
3819
  * eax = value of old activity for this signal (0/1)
-
 
3820
  * eax = -1 - invalid signal number
3816
Remarks:
3821
Remarks:
3817
  * In current implementation, it is changed only exception mask for
3822
  * In current implementation, it is changed only exception mask for
3818
    user exception handler, wich was previously set by subfunction 24.
3823
    user exception handler, wich was previously set by subfunction 24.
3819
    At that, number of signal correspond to exception number.
3824
    At that, number of signal correspond to exception number.
Line 4109... Line 4114...
4109
  * '/rd/1/kernel.asm',0
4114
  * '/rd/1/kernel.asm',0
4110
  * '/HD0/1/kernel.asm',0
4115
  * '/HD0/1/kernel.asm',0
4111
  * '/hd0/2/menuet/pics/tanzania.bmp',0
4116
  * '/hd0/2/menuet/pics/tanzania.bmp',0
4112
  * '/hd0/1/Program files/NameOfProgram/SomeFile.SomeExtension',0
4117
  * '/hd0/1/Program files/NameOfProgram/SomeFile.SomeExtension',0
4113
  * '/sys/MySuperApp.ini',0
4118
  * '/sys/MySuperApp.ini',0
-
 
4119
Also function supports relative names.  If the path begins not 
-
 
4120
with '/', it is considered relative to a current folder. To get or 
-
 
4121
set a current folder, use the function 30.
-
 
4122
 
4114
Available subfunctions:
4123
Available subfunctions:
4115
  * subfunction 0 - read file
4124
  * subfunction 0 - read file
4116
  * subfunction 1 - read folder
4125
  * subfunction 1 - read folder
4117
  * subfunction 2 - create/rewrite file
4126
  * subfunction 2 - create/rewrite file
4118
  * subfunction 3 - write to existing file
4127
  * subfunction 3 - write to existing file