Advertisement
Guest User

KolibriOS system functions and definitions

a guest
Feb 4th, 2017
272
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 135.93 KB | None | 0 0
  1. (************************************************************
  2.  
  3.           KolibriOS system functions and definitions
  4.  
  5.  ************************************************************)
  6. Unit KolibriOS;
  7. (* -------------------------------------------------------- *)
  8. Interface
  9. (* -------------------------------------------------------- *)
  10. Type
  11.  
  12.   Dword = LongWord;
  13.  
  14.   Qword = UInt64;
  15.  
  16.   TSize = Packed Record
  17.     Height: Word;
  18.     Width:  Word;
  19.   End;
  20.  
  21.   TPoint = Packed Record
  22.     Y: SmallInt;
  23.     X: SmallInt;
  24.   End;
  25.  
  26.   TRect = Packed Record
  27.     Left:   LongInt;
  28.     Top:    LongInt;
  29.     Right:  LongInt;
  30.     Bottom: LongInt;
  31.   End;
  32.  
  33.   TBox = Packed Record
  34.     Left:   LongInt;
  35.     Top:    LongInt;
  36.     Width:  Dword;
  37.     Height: Dword;
  38.   End;
  39.  
  40.   TSystemDate = Packed Record
  41.     Year:  Byte;
  42.     Month: Byte;
  43.     Day:   Byte;
  44.     Zero:  Byte;
  45.   End;
  46.  
  47.   TSystemTime = Packed Record
  48.     Hours:   Byte;
  49.     Minutes: Byte;
  50.     Seconds: Byte;
  51.     Zero:    Byte;
  52.   End;
  53.  
  54.   TThreadInfo = Packed Record
  55.     CpuUsage:     Dword;
  56.     WinStackPos:  Word;
  57.     reserved0:    Word;
  58.     reserved1:    Word;
  59.     Name:         Packed Array[0..10] Of Char;
  60.     reserved2:    Byte;
  61.     MemAddress:   Dword;
  62.     MemUsage:     Dword;
  63.     Identifier:   Dword;
  64.     Window:       TRect;
  65.     ThreadState:  Word;
  66.     reserved3:    Word;
  67.     Client:       TRect;
  68.     WindowState:  Byte;
  69.     EventMask:    Dword;
  70.     KeyboardMode: Byte;
  71.     reserved4:    Packed Array[0..947] Of Byte;
  72.   End;
  73.  
  74.   TKeyboardInputMode = (kmASCII, kmSCAN);
  75.  
  76.   TKeyboardInputFlag = (kfCode, kfEmpty, kfHotKey);
  77.  
  78.   TKeyboardInput = Packed Record
  79.     Flag: TKeyboardInputFlag;
  80.     Code: Char;
  81.     Case TKeyboardInputMode Of
  82.       kmASCII: (Scan: Char);
  83.       kmSCAN:  (
  84.                 Case TKeyboardInputFlag Of
  85.                   kfCode:   ();
  86.                   kfHotKey: (Control: Word);          
  87.                );
  88.   End;  
  89.  
  90.   TButtonInput = Packed Record
  91.     MouseButton: Byte;
  92.     ID:          Word;
  93.     HiID:        Byte;
  94.   End;
  95.  
  96.   TKernelVersion = Packed Record
  97.     A, B, C, D: Byte;
  98.     reserved:   Byte;
  99.     Revision:   Dword;
  100.   End;
  101.  
  102.   TRAMInfo = Packed Record
  103.     AvailablePages:    Dword;
  104.     FreePages:         Dword;
  105.     PageFaults:        Dword;
  106.     KernelHeapSize:    Dword;
  107.     KernelHeapFree:    Dword;
  108.     Blocks:            Dword;
  109.     FreeBlocks:        Dword;
  110.     MaxFreeBlock:      Dword;
  111.     MaxAllocatedBlock: Dword;
  112.   End;
  113.  
  114.   TKeyboardLayout = Packed Array[0..127] Of Char;
  115.  
  116.   TCtrlDriver = Packed Record
  117.     Handle:         Dword;
  118.     Func:           Dword;
  119.     InputData:      Pointer;
  120.     InputDataSize:  Dword;
  121.     OutputData:     Pointer;
  122.     OutputDataSize: Dword;
  123.   End;
  124.  
  125.   TFileDate = Packed Record
  126.     Day:   Byte;
  127.     Month: Byte;
  128.     Year:  Word;
  129.   End;
  130.  
  131.   TFileTime = Packed Record
  132.     Seconds: Byte;
  133.     Minutes: Byte;
  134.     Hours:   Byte;
  135.     Zero:    Byte;
  136.   End;
  137.  
  138.   TFileAttributes = Packed Record
  139.     Attributes:   Dword;
  140.     Flags:        Dword;
  141.     CreationTime: TFileTime;
  142.     CreationDate: TFileDate;
  143.     AccessTime:   TFileTime;
  144.     AccessDate:   TFileDate;
  145.     ModifyTime:   TFileTime;
  146.     ModifyDate:   TFileDate;
  147.     SizeLo:       Dword;
  148.     SizeHi:       Dword;
  149.   End;
  150.  
  151.   TFileInformation = Packed Record
  152.     FileAttributes: TFileAttributes;
  153.     FileName:       Packed Array[0..255] Of Char;
  154.     reserved:       Packed Array[0..7] Of Byte;
  155.   End;
  156.  
  157.   TFolderInformation = Packed Record
  158.     Version:         Dword;
  159.     BlockCount:      Dword;
  160.     FileCount:       Dword;
  161.     reserved:        Packed Array[0..19] Of Byte;
  162.     FileInformation: Packed Array[0..0] Of TFileInformation;
  163.   End;
  164.  
  165.   TStandardColors = Packed Record
  166.     Frames:         Dword;
  167.     Grab:           Dword;
  168.     Work3DDark:     Dword;
  169.     Work3DLight:    Dword;
  170.     GrabText:       Dword;
  171.     Work:           Dword;
  172.     WorkButton:     Dword;
  173.     WorkButtonText: Dword;
  174.     WorkText:       Dword;
  175.     WorkGraph:      Dword;
  176.   End;
  177.  
  178.   TSockAddr = Packed Record
  179.     Family: Word;
  180.     Data:   Packed Array[0..13] Of Byte;
  181.   End;
  182.  
  183.   TOptStruct = Packed Record
  184.     Level:     Dword;
  185.     OptName:   Dword;
  186.     OptLength: Dword;
  187.     Options:   Packed Array[0..0] Of Byte
  188.   End;
  189.  
  190.   TThreadContext = Packed Record
  191.     EIP:    Dword;
  192.     EFlags: Dword;
  193.     EAX:    Dword;
  194.     ECX:    Dword;
  195.     EDX:    Dword;
  196.     EBX:    Dword;
  197.     ESP:    Dword;
  198.     EBP:    Dword;
  199.     ESI:    Dword;
  200.     EDI:    Dword;
  201.   End;
  202.  
  203.   TSignalBuffer = Packed Record
  204.     ID:   Dword;
  205.     Data: Packed Array[0..19] Of Byte;
  206.   End;
  207.  
  208.   TIPCMessage = Packed Record
  209.     ID:     Dword;
  210.     Length: Dword;
  211.     Data:   Packed Array[0..0] Of Byte;
  212.   End;
  213.  
  214.   TIPCBuffer = Packed Record
  215.     Lock:        Dword;
  216.     CurrentSize: Dword;
  217.     Data:        Packed Array[0..0] Of TIPCMessage;
  218.   End;
  219.  
  220.   TDebugMessage = Packed Record
  221.     Code: Dword;
  222.     ID:   Dword;
  223.     Data: Dword;
  224.   End;
  225.  
  226.   TDebugBuffer = Packed Record
  227.     TotalSize:   Dword;
  228.     CurrentSize: Dword;
  229.     Buffer:      Packed Array[0..0] Of TDebugMessage;
  230.   End;
  231.  
  232. (* -------------------------------------------------------- *)
  233. Const
  234.  
  235.  (* Window styles *)
  236.   WS_SKINNED_FIXED     =  $4000000;
  237.   WS_SKINNED_SIZABLE   =  $3000000;
  238.   WS_FIXED             =  $0000000;
  239.   WS_SIZABLE           =  $2000000;
  240.   WS_FILL_TRANSPARENT  = $40000000;
  241.   WS_FILL_GRADIENT     = $80000000;
  242.   WS_COORD_CLIENT      = $20000000;
  243.   WS_CAPTION           = $10000000;
  244.  
  245.  (* Caption styles *)
  246.   CAPTION_MOVABLE      = $00000000;
  247.   CAPTION_NONMOVABLE   = $01000000;
  248.  
  249.  (* Events *)
  250.   REDRAW_EVENT         = 1;
  251.   KEY_EVENT            = 2;
  252.   BUTTON_EVENT         = 3;
  253.   BACKGROUND_EVENT     = 5;
  254.   MOUSE_EVENT          = 6;
  255.   IPC_EVENT            = 7;
  256.   NETWORK_EVENT        = 8;
  257.   DEBUG_EVENT          = 9;
  258.  
  259.  (* Event Mask Constants *)
  260.   EM_REDRAW            = $001;
  261.   EM_KEY               = $002;
  262.   EM_BUTTON            = $004;
  263.   EM_BACKGROUND        = $010;
  264.   EM_MOUSE             = $020;
  265.   EM_IPC               = $040;
  266.   EM_NETWORK           = $080;
  267.   EM_DEBUG             = $100;
  268.  
  269.  (* Size multipliers for DrawText *)
  270.   DT_X1                =  $0000000;
  271.   DT_X2                =  $1000000;
  272.   DT_X3                =  $2000000;
  273.   DT_X4                =  $3000000;
  274.   DT_X5                =  $4000000;
  275.   DT_X6                =  $5000000;
  276.   DT_X7                =  $6000000;
  277.   DT_X8                =  $7000000;
  278.  
  279.  (* Charset specifiers for DrawText *)
  280.   DT_CP866_6X9         = $00000000;
  281.   DT_CP866_8X16        = $10000000;
  282.   DT_UTF_16LE_8X16     = $20000000;
  283.   DT_UTF_8_8X16        = $30000000;
  284.  
  285.  (* Fill styles for DrawText *)
  286.   DT_FILL_TRANSPARENT  = $00000000;
  287.   DT_FILL_OPAQUE       = $40000000;
  288.  
  289.  (* Draw zero terminated string for DrawText *)
  290.   DT_ZSTRING           = $80000000;
  291.  
  292.  (* Button styles *)
  293.   BS_FILL_TRANSPARENT  = $40000000;
  294.   BS_NO_FRAME          = $20000000;
  295.  
  296.  (* SharedMemoryOpen open\access flags *)
  297.   SHM_OPEN             = $00;
  298.   SHM_OPEN_ALWAYS      = $04;
  299.   SHM_CREATE           = $08;
  300.   SHM_READ             = $00;
  301.   SHM_WRITE            = $01;
  302.  
  303.  (* KeyboardLayout flags *)
  304.   KBL_NORMAL           = 1;
  305.   KBL_SHIFT            = 2;
  306.   KBL_ALT              = 3;
  307.  
  308.  (* SystemShutdown parameters *)
  309.   SHUTDOWN_TURNOFF     = 2;
  310.   SHUTDOWN_REBOOT      = 3;
  311.   SHUTDOWN_RESTART     = 4;
  312.  
  313.  (* Blit flags *)  
  314.   BLIT_CLIENT_RELATIVE = $20000000;
  315.  
  316. (* -------------------------------------------------------- *)
  317. {-1}      Procedure ThreadTerminate; StdCall;
  318. {0}       Procedure DrawWindow(Left, Top, Right, Bottom: Integer; Caption: PChar; BackColor, Style, CapStyle: Dword); StdCall;
  319. {1}       Procedure SetPixel(X, Y: Integer; Color: Dword); StdCall;
  320. {2}       Function  GetKey: TKeyboardInput; StdCall;
  321. {3}       Function  GetSystemTime: TSystemTime; StdCall;
  322. {4}       Procedure DrawText(X, Y: Integer; Text: PChar; ForeColor, BackColor, Flags, Count: Dword); StdCall;
  323. {5}       Procedure Sleep(Time: Dword); StdCall;
  324. {6}       {UNDEFINED}
  325. {7}       Procedure DrawImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  326. {8}       Procedure DrawButton(Left, Top, Right, Bottom: Integer; BackColor, Style, ID: Dword); StdCall;
  327. {8}       Procedure DeleteButton(ID: Dword); StdCall;
  328. {9}       Function  GetThreadInfo(Slot: Dword; Var Buffer: TThreadInfo): Dword; StdCall;
  329. {10}      Function  WaitEvent: Dword; StdCall;
  330. {11}      Function  CheckEvent: Dword; StdCall;
  331. {12.1}    Procedure BeginDraw; StdCall;
  332. {12.2}    Procedure EndDraw; StdCall;
  333. {13}      Procedure DrawRectangle(X, Y: Integer; Width, Height: Dword; Color: Dword); StdCall;
  334. {14}      Function  GetScreenMax: TPoint; StdCall;
  335. {15.1}    Procedure SetBackgroundSize(Width, Height: Dword); StdCall;
  336. {15.2}    Procedure SetBackgroundPixel(X, Y: Integer; Color: Dword); StdCall;
  337. {15.3}    Procedure DrawBackground; StdCall;
  338. {15.4}    Procedure SetBackgroundDrawMode(DrawMode: Dword); StdCall;
  339. {15.5}    Procedure DrawBackgroundImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  340. {15.6}    Function  MapBackground: Pointer; StdCall;
  341. {15.7}    Function  UnMapBackground(Background: Pointer): Integer; StdCall;
  342. {15.8}    Function  GetLastDrawnBackgroundRect: TRect; StdCall;
  343. {15.9}    Procedure UpdateBackgroundRect(Left, Top, Right, Bottom: Integer); StdCall;
  344. {16}      Function  FlushFloppyCache(FloppyNumber: Dword): Dword; StdCall;
  345. {17}      Function  GetButton: TButtonInput; StdCall;
  346. {18.1}    Procedure DeactivateWindow(Slot: Dword); StdCall;
  347. {18.2}    Procedure ThreadTerminateBySlot(Slot: Dword); StdCall;
  348. {18.3}    Procedure ActivateWindow(Slot: Dword); StdCall;
  349. {18.4}    Function  GetIdleTime: Dword; StdCall;
  350. {18.5}    Function  GetCPUClock: Dword; StdCall;
  351. {18.6}    Function  SaveRamDisk(Path: PChar): Dword; StdCall;
  352. {18.7}    Function  GetActiveWindow: Dword; StdCall;
  353. {18.8.1}  Function  GetSpeakerState: Integer; StdCall;
  354. {18.8.2}  Procedure SwitchSpeakerState; StdCall;
  355. {18.9}    Function  SystemShutdown(Param: Dword): Integer; StdCall;
  356. {18.10}   Procedure MinimizeActiveWindow; StdCall;
  357. {18.11}   Procedure GetDiskSystemInfo(Var Buffer); StdCall;
  358. {18.12}   {UNDEFINED}
  359. {18.13}   Procedure GetKernelVersion(Var Buffer: TKernelVersion); StdCall;
  360. {18.14}   Function  WaitRetrace: Integer; StdCall;
  361. {18.15}   Function  CenterMousePointer: Integer; StdCall;
  362. {18.16}   Function  GetFreeMemory: Dword; StdCall;
  363. {18.17}   Function  GetAvailableMemory: Dword; StdCall;
  364. {18.18}   Function  ThreadTerminateById(ID: Dword): Integer; StdCall;
  365. {18.19.0} Function  GetMouseSpeed: Dword; StdCall;
  366. {18.19.1} Procedure SetMouseSpeed(Speed: Dword); StdCall;
  367. {18.19.2} Function  GetMouseSensitivity: Dword; StdCall;
  368. {18.19.3} Procedure SetMouseSensitivity(Sensitivity: Dword); StdCall;
  369. {18.19.4} Procedure SetMousePos(X, Y: Integer); StdCall;
  370. {18.19.5} Procedure SetMouseButtons(State: Dword); StdCall;
  371. {18.19.6} Function  GetDoubleClickTime: Dword; StdCall;
  372. {18.19.7} Procedure SetDoubleClickTime(Time: Dword); StdCall;
  373. {18.20}   Function  GetRAMInfo(Var Buffer: TRAMInfo): Integer; StdCall;
  374. {18.21}   Function  GetSlotById(ID: Dword): Dword; StdCall;
  375. {18.22.0} Function  MinimizeWindowBySlot(Slot: Dword): Integer; StdCall;
  376. {18.22.1} Function  MinimizeWindowByID(ID: Dword): Integer; StdCall;
  377. {18.22.2} Function  RestoreWindowBySlot(Slot: Dword): Integer; StdCall;
  378. {18.22.3} Function  RestoreWindowByID(ID: Dword): Integer; StdCall;
  379. {18.23}   Function  MinimizeAllWindows: Dword; StdCall;
  380. {18.24}   Procedure SetScreenLimits(Width, Height: Dword); StdCall;
  381. {18.25.1} Function  GetWindowZOrder(ID: Dword): Dword; StdCall;
  382. {18.25.2} Function  SetWindowZOrder(ID, ZOrder: Dword): Integer; StdCall;
  383. {19}      {UNDEFINED}
  384. {20.1}    Function  ResetMidi: Integer; StdCall;
  385. {20.2}    Function  OutputMidi(Data: Byte): Integer; StdCall;
  386. {21.1}    Function  SetMidiBase(Port: Dword): Integer; StdCall;
  387. {21.2}    Function  SetKeyboardLayout(Flags: Dword; Var Table: TKeyboardLayout): Integer; StdCall;
  388. {21.2}    Function  SetKeyboardLayoutCountry(Country: Dword): Integer; StdCall;
  389. {21.3}    {UNDEFINED}
  390. {21.4}    {UNDEFINED}
  391. {21.5}    Function  SetSystemLanguage(SystemLanguage: Dword): Integer; StdCall;
  392. {21.6}    {UNDEFINED}
  393. {21.7}    {UNDEFINED}
  394. {21.8}    {UNDEFINED}
  395. {21.9}    {UNDEFINED}
  396. {21.10}   {UNDEFINED}
  397. {21.11}   Function  SetHDAccess(Value: Dword): Integer; StdCall;
  398. {21.12}   Function  SetPCIAccess(Value: Dword): Integer; StdCall;
  399. {22.0}    Function  SetSystemTime(Time: TSystemTime): Integer; StdCall;
  400. {22.1}    Function  SetSystemDate(Date: TSystemDate): Integer; StdCall;
  401. {22.2}    Function  SetDayOfWeek(DayOfWeek: Dword): Integer; StdCall;
  402. {22.3}    Function  SetAlarm(Time: TSystemTime): Integer; StdCall;
  403. {23}      Function  WaitEventByTime(Time: Dword): Dword; StdCall;
  404. {24.4}    Procedure OpenCDTray(Drive: Dword); StdCall;
  405. {24.5}    Procedure CloseCDTray(Drive: Dword); StdCall;
  406. {25}      Procedure DrawBackgroundLayerImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  407. {26.1}    Function  GetMidiBase: Dword; StdCall;
  408. {26.2}    Procedure GetKeyboardLayout(Flags: Dword; Var Table: TKeyboardLayout); StdCall;
  409. {26.2}    Function  GetKeyboardLayoutCountry: Dword; StdCall;
  410. {26.3}    {UNDEFINED}
  411. {26.4}    {UNDEFINED}
  412. {26.5}    Function  GetSystemLanguage: Dword; StdCall;
  413. {26.6}    {UNDEFINED}
  414. {26.7}    {UNDEFINED}
  415. {26.8}    {UNDEFINED}
  416. {26.9}    Function  GetTickCount: Dword; StdCall;
  417. {26.10}   Function  GetTickCount64: Qword; StdCall;
  418. {26.11}   Function  IsHDAccessAllowed: Dword; StdCall;
  419. {26.12}   Function  IsPCIAccessAllowed: Dword; StdCall;
  420. {27}      {UNDEFINED}
  421. {28}      {UNDEFINED}
  422. {29}      Function  GetSystemDate: TSystemDate; StdCall;
  423. {30.1}    Procedure SetCurrentDirectory(Path: PChar); StdCall;
  424. {30.2}    Function  GetCurrentDirectory(Buffer: PChar; Count: Dword): Dword; StdCall;
  425. {31}      {UNDEFINED}
  426. {32}      {UNDEFINED}
  427. {33}      {UNDEFINED}
  428. {34}      Function  GetPointOwner(X, Y: Integer): Dword; StdCall;
  429. {35}      Function  GetPixel(X, Y: Integer): Dword; StdCall;
  430. {36}      Procedure GetScreenImage(Var Buffer; X, Y: Integer; Width, Height: Dword); StdCall;
  431. {37.0}    Function  GetMousePos: TPoint; StdCall;
  432. {37.1}    Function  GetWindowMousePos: TPoint; StdCall;
  433. {37.2}    Function  GetMouseButtons: Dword; StdCall;
  434. {37.3}    Function  GetMouseEvents: Dword; StdCall;
  435. {37.4}    Function  LoadCursorFromFile(Path: PChar): Dword; StdCall;
  436. {37.4}    Function  LoadCursorFromMemory(Const Buffer): Dword; StdCall;
  437. {37.4}    Function  LoadCursorIndirect(Const Buffer; HotSpotX, HotSpotY: ShortInt): Dword; StdCall;
  438. {37.5}    Function  SetCursor(Handle: Dword): Dword; StdCall;
  439. {37.6}    Function  DeleteCursor(Handle: Dword): Dword; StdCall;
  440. {37.7}    Function  GetMouseScroll: TPoint; StdCall;
  441. {38}      Procedure DrawLine(X1, Y1, X2, Y2: Integer; Color: Dword); StdCall;
  442. {39.1}    Function  GetBackgroundSize: TSize; StdCall;
  443. {39.2}    Function  GetBackgroundPixel(X, Y: Integer): Dword; StdCall;
  444. {39.3}    {UNDEFINED}
  445. {39.4}    Function  GetBackgroundDrawMode: Dword; StdCall;
  446. {40}      Function  SetEventMask(Mask: Dword): Dword; StdCall;
  447. {41}      {UNDEFINED}
  448. {42}      {UNDEFINED}
  449. {43}      Function  InPort(Port: Dword; Var Data: Byte): Dword; StdCall;
  450. {43}      Function  OutPort(Port: Dword; Data: Byte): Dword; StdCall;
  451. {44}      {UNDEFINED}
  452. {45}      {UNDEFINED}
  453. {46}      Function  ReservePorts(First, Last: Dword): Dword; StdCall;
  454. {46}      Function  FreePorts(First, Last: Dword): Dword; StdCall;
  455. {47}      {DrawNumber}
  456. {48.0}    Procedure ApplyStyleSettings; StdCall;
  457. {48.1}    Procedure SetButtonStyle(ButtonStyle: Dword); StdCall;
  458. {48.2}    Procedure SetStandardColors(Var ColorTable: TStandardColors; Size: Dword); StdCall;
  459. {48.3}    Procedure GetStandardColors(Var ColorTable: TStandardColors; Size: Dword); StdCall;
  460. {48.4}    Function  GetSkinHeight: Dword; StdCall;
  461. {48.5}    Function  GetScreenWorkingArea: TRect; StdCall;
  462. {48.6}    Procedure SetScreenWorkingArea(Left, Top, Right, Bottom: Integer); StdCall;
  463. {48.7}    Function  GetSkinMargins: TRect; StdCall;
  464. {48.8}    Function  SetSkin(Path: PChar): Integer; StdCall;
  465. {48.9}    Function  GetFontSmoothing: Integer; StdCall;
  466. {48.10}   Procedure SetFontSmoothing(Smoothing: Integer); StdCall;
  467. {48.11}   Function  GetFontHeight: Dword; StdCall;
  468. {48.12}   Procedure SetFontHeight(Height: Dword); StdCall;
  469. {49}      {Advanced Power Management}
  470. {50.0}    Procedure SetWindowShape(Const Data); StdCall;
  471. {50.1}    Procedure SetWindowScale(Scale: Dword); StdCall;
  472. {51.1}    Function  ThreadCreate(Entry, Stack: Pointer): Dword; StdCall;
  473. {52}      {UNDEFINED}
  474. {53}      {UNDEFINED}
  475. {54.0}    Function  GetClipboardSlotCount: Integer; StdCall;
  476. {54.1}    Function  GetClipboardData(Slot: Dword): Pointer; StdCall;
  477. {54.2}    Function  SetClipboardData(Const Src; Count: Dword): Integer; StdCall;
  478. {54.3}    Function  DeleteClipboardLastSlot: Integer; StdCall;
  479. {54.4}    Function  ResetClipboard: Integer; StdCall;
  480. {55}      Function  SpeakerPlay(Const Data): Dword; StdCall;
  481. {56}      {UNDEFINED}
  482. {57}      {PCI BIOS}
  483. {58}      {UNDEFINED}
  484. {59}      {UNDEFINED}
  485. {60.1}    Function  IPCSetBuffer(Const Buffer: TIPCBuffer; Size: Dword): Integer; StdCall;
  486. {60.2}    Function  IPCSendMessage(ID: Dword; Var Msg: TIPCMessage; Size: Dword): Integer; StdCall;
  487. {61.1}    Function  GetScreenSize: TSize; StdCall;
  488. {61.2}    Function  GetScreenBitsPerPixel: Dword; StdCall;
  489. {61.3}    Function  GetScreenBytesPerScanLine: Dword; StdCall;
  490. {62.0}    Function  GetPCIVersion: Dword; StdCall;
  491. {62.1}    Function  GetLastPCIBus: Dword; StdCall;
  492. {62.2}    Function  GetPCIAddressingMode: Dword; StdCall;
  493. {62.3}    {UNDEFINED}
  494. {62.4}    Function  ReadPCIByte(Bus, Device, Func, Reg: Byte): Byte; StdCall;
  495. {62.5}    Function  ReadPCIWord(Bus, Device, Func, Reg: Byte): Word; StdCall;
  496. {62.6}    Function  ReadPCIDword(Bus, Device, Func, Reg: Byte): Dword; StdCall;
  497. {62.7}    {UNDEFINED}
  498. {62.8}    Function  WritePCIByte(Bus, Device, Func, Reg: Byte; Data: Byte): Dword; StdCall;
  499. {62.9}    Function  WritePCIWord(Bus, Device, Func, Reg: Byte; Data: Word): Dword; StdCall;
  500. {62.10}   Function  WritePCIDword(Bus, Device, Func, Reg: Byte; Data: Dword): Dword; StdCall;
  501. {63.1}    Procedure BoardWriteByte(Data: Byte); StdCall;
  502. {63.2}    Function  BoardReadByte(Var Data: Byte): Dword; StdCall;
  503. {64}      Function  ReallocAppMemory(Count: Dword): Integer; StdCall;
  504. {65}      Procedure DrawImageEx(Const Image; Left, Top: Integer; Width, Height: Dword; BPP: Dword; Const Palette: Pointer; Padding: Dword); StdCall;
  505. {66.1}    Procedure SetKeyboardInputMode(Mode: Dword); StdCall;
  506. {66.2}    Function  GetKeyboardInputMode: Dword; StdCall;
  507. {66.3}    Function  GetControlKeyState: Dword; StdCall;
  508. {66.4}    Function  SetHotKey(ScanCode, Control: Dword): Integer; StdCall;
  509. {66.5}    Function  ResetHotKey(ScanCode, Control: Dword): Integer; StdCall;
  510. {66.6}    Procedure KeyboardLock; StdCall;
  511. {66.7}    Procedure KeyboardUnlock; StdCall;
  512. {67}      Procedure SetWindowPos(Left, Top, Right, Bottom: Integer); StdCall;
  513. {68.0}    Function  GetTaskSwitchCount: Dword; StdCall;
  514. {68.1}    Procedure SwitchThread; StdCall;
  515. {68.2.0}  Function  EnableRDPMC: Dword; StdCall;
  516. {68.2.1}  Function  IsCacheEnabled: Dword; StdCall;
  517. {68.2.2}  Procedure EnableCache; StdCall;
  518. {68.2.3}  Procedure DisableCache; StdCall;
  519. {68.3}    {ReadMSR}
  520. {68.4}    {WriteMSR}
  521. {68.5}    {UNDEFINED}
  522. {68.6}    {UNDEFINED}
  523. {68.7}    {UNDEFINED}
  524. {68.8}    {UNDEFINED}
  525. {68.9}    {UNDEFINED}
  526. {68.10}   {UNDEFINED}
  527. {68.11}   Function  HeapCreate: Dword; StdCall;
  528. {68.12}   Function  HeapAllocate(Bytes: Dword): Pointer; StdCall;
  529. {68.13}   Function  HeapFree(MemPtr: Pointer): Dword; StdCall;
  530. {68.14}   Procedure WaitSignal(Var Buffer: TSignalBuffer); StdCall;
  531. {68.15}   {UNDEFINED}
  532. {68.16}   Function  GetDriver(Name: PChar): Dword; StdCall;
  533. {68.17}   Function  ControlDriver(Var CtrlStructure: TCtrlDriver): Dword; StdCall;
  534. {68.18}   {UNDEFINED}
  535. {68.19}   Function  LoadLibrary(Path: PChar): Pointer; StdCall;
  536. {68.20}   Function  HeapReallocate(MemPtr: Pointer; Bytes: Dword): Pointer; StdCall;
  537. {68.21}   Function  LoadDriver(Name, CmdLine: PChar): Dword; StdCall;
  538. {68.22}   Function  SharedMemoryOpen(Name: PChar; Bytes: Dword; Flags: Dword): Pointer; StdCall;
  539. {68.23}   Function  SharedMemoryClose(Name: PChar): Dword; StdCall;
  540. {68.24}   Function  SetExceptionHandler(Handler: Pointer; Mask: Dword; Var OldMask: Dword): Pointer; StdCall;
  541. {68.25}   Function  SetExceptionActivity(Signal, Activity: Dword): Integer; StdCall;
  542. {68.26}   Procedure ReleaseMemoryPages(MemPtr: Pointer; Offset, Size: Dword); StdCall;
  543. {68.27}   Function  LoadFile(Path: PChar; Var Size: Dword): Pointer; StdCall;
  544. {69.0}    Procedure SetDebugBuffer(Const Buffer: TDebugBuffer); StdCall;
  545. {69.1}    Procedure GetThreadContext(ID: Dword; Var Context: TThreadContext); StdCall;
  546. {69.2}    Procedure SetThreadContext(ID: Dword; Const Context: TThreadContext); StdCall;
  547. {69.3}    Procedure DetachThread(ID: Dword); StdCall;
  548. {69.4}    Procedure SuspendThread(ID: Dword); StdCall;
  549. {69.5}    Procedure ResumeThread(ID: Dword); StdCall;
  550. {69.6}    Function  ReadProcessMemory(ID, Count: Dword; Const Src; Var Dst): Integer; StdCall;
  551. {69.7}    Function  WriteProcessMemory(ID, Count: Dword; Const Src; Var Dst): Integer; StdCall;
  552. {69.8}    Procedure DebugTerminate(ID: Dword); StdCall;
  553. {69.9}    Function  SetBreakPoint(ID: Dword; Index, Flags: Byte; Address: Pointer): Integer; StdCall;
  554. {69.9}    Function  ResetBreakPoint(ID: Dword; Index, Flags: Byte; Address: Pointer): Integer; StdCall;
  555. {70.0}    Function  ReadFile(Path: PChar; Var Buffer; Count, LoPos, HiPos: Cardinal; Var BytesRead: Dword): Integer; StdCall;
  556. {70.1}    Function  ReadFolder(Path: PChar; Var Buffer; Count, Start, Flags: Cardinal; Var BlocksRead: Dword): Integer; StdCall;
  557. {70.2}    Function  CreateFile(Path: PChar): Integer; StdCall;
  558. {70.3}    Function  WriteFile(Path: PChar; Const Buffer; Count, LoPos, HiPos: Cardinal; Var BytesWritten: Dword): Integer; StdCall;
  559. {70.4}    Function  ResizeFile(Path: PChar; LoSize, HiSize: Cardinal): Integer; StdCall;
  560. {70.5}    Function  GetFileAttributes(Path: PChar; Var Buffer: TFileAttributes): Integer; StdCall;
  561. {70.6}    Function  SetFileAttributes(Path: PChar; Var Buffer: TFileAttributes): Integer; StdCall;
  562. {70.7}    Function  RunFile(Path, CmdLine: PChar): Integer; StdCall;
  563. {70.7}    Function  DebugFile(Path, CmdLine: PChar): Integer; StdCall;
  564. {70.8}    Function  DeleteFile(Path: PChar): Integer; StdCall;
  565. {70.9}    Function  CreateFolder(Path: PChar): Integer; StdCall;
  566. {71.1}    Procedure SetWindowCaption(Caption: PChar); StdCall;
  567. {72.1.2}  Function  SendActiveWindowKey(KeyCode: Dword): Integer; StdCall;
  568. {72.1.3}  Function  SendActiveWindowButton(ButtonID: Dword): Integer; StdCall;
  569. {73}      Procedure Blit(Const Src; SrcX, SrcY: Integer; SrcW, SrcH: Dword; DstX, DstY: Integer; DstW, DstH: Dword; Stride, Flags: Dword); StdCall;
  570. {74.-1}   Function  GetActiveNetworkDevices: Dword; StdCall;
  571. {74.0}    Function  GetNetworkDeviceType(Device: Byte): Integer; StdCall;
  572. {74.1}    Function  GetNetworkDeviceName(Device: Byte; Var Buffer): Integer; StdCall;
  573. {74.2}    Function  ResetNetworkDevice(Device: Byte): Integer; StdCall;
  574. {74.3}    Function  StopNetworkDevice(Device: Byte): Integer; StdCall;
  575. {74.4}    Function  GetNetworkDevicePointer(Device: Byte): Pointer; StdCall;
  576. {74.5}    {UNDEFINED}
  577. {74.6}    Function  GetSentPackets(Device: Byte): Integer; StdCall;
  578. {74.7}    Function  GetReceivedPackets(Device: Byte): Integer; StdCall;
  579. {74.8}    Function  GetSentBytes(Device: Byte): Integer; StdCall;
  580. {74.9}    Function  GetReceivedBytes(Device: Byte): Integer; StdCall;
  581. {74.10}   Function  GetLinkStatus(Device: Byte): Integer; StdCall;
  582. {75.0}    Function  OpenSocket(Domain, Kind, Protocol: Dword): Dword; StdCall;
  583. {75.1}    Function  CloseSocket(Socket: Dword): Integer; StdCall;
  584. {75.2}    Function  SocketBind(Socket: Dword; Var SockAddr: TSockAddr): Integer; StdCall;
  585. {75.3}    Function  SocketListen(Socket: Dword; Var BackLog): Integer; StdCall;
  586. {75.4}    Function  SocketConnect(Socket: Dword; Var SockAddr: TSockAddr): Integer; StdCall;
  587. {75.5}    Function  SocketAccept(Socket: Dword; Var SockAddr: TSockAddr): Dword; StdCall;
  588. {75.6}    Function  SocketSend(Socket: Dword; Const Buffer; Size, Flags: Dword): Integer; StdCall;
  589. {75.7}    Function  SocketReceive(Socket: Dword; Var Buffer; Size, Flags: Dword): Integer; StdCall;
  590. {75.8}    Function  SetSocketOptions(Socket: Dword; Var OptStruct: TOptStruct): Integer; StdCall;
  591. {75.9}    Function  GetSocketOptions(Socket: Dword; Var OptStruct: TOptStruct): Integer; StdCall;
  592. {75.10}   Function  GetSocketPair(Var Socket1, Socket2: Dword): Integer; StdCall;
  593. {76.0.0}  Function  GetMAC(Device: Byte): Dword; StdCall;
  594. {76.1.0}  Function  GetIPv4SentPackets(Device: Byte): Dword; StdCall;
  595. {76.1.1}  Function  GetIPv4ReceivedPackets(Device: Byte): Dword; StdCall;
  596. {76.1.2}  Function  GetIPv4IP(Device: Byte): Dword; StdCall;
  597. {76.1.3}  Function  SetIPv4IP(Device: Byte; IP: Dword): Dword; StdCall;
  598. {76.1.4}  Function  GetIPv4DNS(Device: Byte): Dword; StdCall;
  599. {76.1.5}  Function  SetIPv4DNS(Device: Byte; DNS: Dword): Dword; StdCall;
  600. {76.1.6}  Function  GetIPv4Subnet(Device: Byte): Dword; StdCall;
  601. {76.1.7}  Function  SetIPv4Subnet(Device: Byte; Subnet: Dword): Dword; StdCall;
  602. {76.1.8}  Function  GetIPv4Gateway(Device: Byte): Dword; StdCall;
  603. {76.1.9}  Function  SetIPv4Gateway(Device: Byte; Gateway: Dword): Dword; StdCall;
  604. {76.2.0}  Function  GetICMPSentPackets(Device: Byte): Dword; StdCall;
  605. {76.2.1}  Function  GetICMPReceivedPackets(Device: Byte): Dword; StdCall;
  606. {76.3.0}  Function  GetUDPSentPackets(Device: Byte): Dword; StdCall;
  607. {76.3.1}  Function  GetUDPReceivedPackets(Device: Byte): Dword; StdCall;
  608. {76.4.0}  Function  GetTCPSentPackets(Device: Byte): Dword; StdCall;
  609. {76.4.1}  Function  GetTCPReceivedPackets(Device: Byte): Dword; StdCall;
  610. {76.5.0}  Function  GetARPSentPackets(Device: Byte): Dword; StdCall;
  611. {76.5.1}  Function  GetARPReceivedPackets(Device: Byte): Dword; StdCall;
  612. {76.5.2}  Function  GetARPEntrys(Device: Byte): Dword; StdCall;
  613. {76.5.3}  Function  GetARPEntry(Device: Byte; Entry: Dword; Var Buffer): Dword; StdCall;
  614. {76.5.4}  Function  AddARPEntry(Device: Byte; Const Buffer): Dword; StdCall;
  615. {76.5.5}  Function  RemoveARPEntry(Device: Byte; Entry: Dword): Dword; StdCall;
  616. {76.5.6}  Function  SendARPAnnounce(Device: Byte): Dword; StdCall;
  617. {76.5.7}  Function  GetARPConflicts(Device: Byte): Dword; StdCall;
  618. {77.0}    Function  CreateFutex(Futex: Pointer): Dword; StdCall;
  619. {77.1}    Function  DestroyFutex(Handle: Dword): Dword; StdCall;
  620. {77.2}    Function  WaitFutex(Handle, Value, Time: Dword): Dword; StdCall;
  621. {77.3}    Function  WakeFutex(Handle, Waiters: Dword): Dword; StdCall;
  622.           Function  GetProcAddress(hLib: Pointer; ProcName: PChar): Pointer; StdCall;
  623. (* -------------------------------------------------------- *)
  624. Implementation
  625. (* -------------------------------------------------------- *)
  626. {-1}      Procedure ThreadTerminate; StdCall;
  627.           Asm
  628.                   mov    eax, $FFFFFFFF
  629.                   int    64
  630.           End;
  631. (* -------------------------------------------------------- *)
  632. {0}       Procedure DrawWindow(Left, Top, Right, Bottom: Integer; Caption: PChar; BackColor, Style, CapStyle: Dword); StdCall;
  633.           Asm
  634.                   push   ebx
  635.                   push   edi
  636.                   push   esi
  637.                   xor    eax, eax
  638.                   mov    ebx, Left
  639.                   mov    ecx, Top
  640.                   shl    ebx, 16
  641.                   shl    ecx, 16
  642.                   or     ebx, Right
  643.                   or     ecx, Bottom
  644.                   mov    edx, Style
  645.                   or     edx, BackColor
  646.                   mov    edi, Caption
  647.                   mov    esi, CapStyle
  648.                   int    64
  649.                   pop    esi
  650.                   pop    edi
  651.                   pop    ebx
  652.           End;
  653. (* -------------------------------------------------------- *)
  654. {1}       Procedure SetPixel(X, Y: Integer; Color: Dword); StdCall;
  655.           Asm
  656.                   push   ebx
  657.                   mov    eax, 1
  658.                   mov    ebx, X
  659.                   mov    ecx, Y
  660.                   mov    edx, Color
  661.                   int    64
  662.                   pop    ebx
  663.           End;
  664. (* -------------------------------------------------------- *)
  665. {2}       Function  GetKey: TKeyboardInput; StdCall;
  666.           Asm
  667.                   mov    eax, 2
  668.                   int    64
  669.           End;
  670. (* -------------------------------------------------------- *)
  671. {3}       Function  GetSystemTime: TSystemTime; StdCall;
  672.           Asm
  673.                   mov    eax, 3
  674.                   int    64
  675.           End;
  676. (* -------------------------------------------------------- *)
  677. {4}       Procedure DrawText(X, Y: Integer; Text: PChar; ForeColor, BackColor, Flags, Count: Dword); StdCall;
  678.           Asm
  679.                   push   ebx
  680.                   push   edi
  681.                   push   esi
  682.                   mov    eax, 4
  683.                   mov    ebx, X
  684.                   shl    ebx, 16
  685.                   or     ebx, Y
  686.                   mov    ecx, Flags
  687.                   or     ecx, ForeColor
  688.                   mov    edx, Text
  689.                   mov    edi, BackColor
  690.                   mov    esi, Count
  691.                   int    64
  692.                   pop    esi
  693.                   pop    edi
  694.                   pop    ebx
  695.           End;
  696. (* -------------------------------------------------------- *)
  697. {5}       Procedure Sleep(Time: Dword); StdCall;
  698.           Asm
  699.                   push   ebx
  700.                   mov    eax, 5
  701.                   mov    ebx, Time
  702.                   int    64
  703.                   pop    ebx
  704.           End;
  705. (* -------------------------------------------------------- *)
  706. {6}       {UNDEFINED}
  707. (* -------------------------------------------------------- *)
  708. {7}       Procedure DrawImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  709.           Asm
  710.                   push   ebx
  711.                   mov    eax, 7
  712.                   mov    ebx, Image
  713.                   mov    ecx, Width
  714.                   mov    edx, X    
  715.                   shl    ecx, 16    
  716.                   shl    edx, 16    
  717.                   or     ecx, Height
  718.                   or     edx, Y
  719.                   int    64
  720.                   pop    ebx
  721.           End;
  722. (* -------------------------------------------------------- *)
  723. {8}       Procedure DrawButton(Left, Top, Right, Bottom: Integer; BackColor, Style, ID: Dword); StdCall;
  724.           Asm
  725.                   push   ebx
  726.                   push   esi
  727.                   mov    eax, 8
  728.                   mov    ebx, Left
  729.                   mov    ecx, Top
  730.                   shl    ebx, 16
  731.                   shl    ecx, 16
  732.                   or     ebx, Right
  733.                   or     ecx, Bottom
  734.                   mov    edx, ID
  735.                   or     edx, Style
  736.                   mov    esi, BackColor
  737.                   int    64
  738.                   pop    esi
  739.                   pop    ebx
  740.           End;
  741. (* -------------------------------------------------------- *)
  742. {8}       Procedure DeleteButton(ID: Dword); StdCall;
  743.           Asm
  744.                   mov    eax, 8
  745.                   mov    edx, ID
  746.                   or     edx, $80000000
  747.                   int    64
  748.           End;
  749. (* -------------------------------------------------------- *)
  750. {9}       Function  GetThreadInfo(Slot: Dword; Var Buffer: TThreadInfo): Dword; StdCall;
  751.           Asm
  752.                   push   ebx
  753.                   mov    eax, 9
  754.                   mov    ebx, Buffer
  755.                   mov    ecx, Slot
  756.                   int    64
  757.                   pop    ebx
  758.           End;
  759. (* -------------------------------------------------------- *)
  760. {10}      Function  WaitEvent: Dword; StdCall;
  761.           Asm
  762.                   mov    eax, 10
  763.                   int    64
  764.           End;
  765. (* -------------------------------------------------------- *)
  766. {11}      Function  CheckEvent: Dword; StdCall;
  767.           Asm
  768.                   mov    eax, 11
  769.                   int    64
  770.           End;
  771. (* -------------------------------------------------------- *)
  772. {12.1}    Procedure BeginDraw; StdCall;
  773.           Asm
  774.                   push   ebx
  775.                   mov    eax, 12
  776.                   mov    ebx, 1
  777.                   int    64
  778.                   pop    ebx
  779.           End;
  780. (* -------------------------------------------------------- *)
  781. {12.2}    Procedure EndDraw; StdCall;
  782.           Asm
  783.                   push   ebx
  784.                   mov    eax, 12
  785.                   mov    ebx, 2
  786.                   int    64
  787.                   pop    ebx
  788.           End;
  789. (* -------------------------------------------------------- *)
  790. {13}      Procedure DrawRectangle(X, Y: Integer; Width, Height: Dword; Color: Dword); StdCall;
  791.           Asm
  792.                   push   ebx
  793.                   mov    eax, 13
  794.                   mov    ebx, X
  795.                   mov    ecx, Y
  796.                   mov    edx, Color
  797.                   shl    ebx, 16
  798.                   shl    ecx, 16
  799.                   or     ebx, Width
  800.                   or     ecx, Height
  801.                   int    64
  802.                   pop    ebx
  803.           End;
  804. (* -------------------------------------------------------- *)
  805. {14}      Function  GetScreenMax: TPoint; StdCall;
  806.           Asm
  807.                   mov    eax, 14
  808.                   int    64
  809.           End;
  810. (* -------------------------------------------------------- *)
  811. {15.1}    Procedure SetBackgroundSize(Width, Height: Dword); StdCall;
  812.           Asm
  813.                   push   ebx
  814.                   mov    eax, 15
  815.                   mov    ebx, 1
  816.                   mov    ecx, Width
  817.                   mov    edx, Height
  818.                   int    64
  819.                   pop    ebx
  820.           End;
  821. (* -------------------------------------------------------- *)
  822. {15.2}    Procedure SetBackgroundPixel(X, Y: Integer; Color: Dword); StdCall;
  823.           Asm
  824.                   push   ebx
  825.           // at first need to know Background.Width
  826.                   mov    eax, 39
  827.                   mov    ebx, 1
  828.                   int    64
  829.           // at now eax = (Width << 16) | Height
  830.           // need to make ecx = (X + Y * Background.Width) * 3
  831.                   shr    eax, 16
  832.                   mul    Y
  833.                   add    eax, X
  834.                   mov    ecx, eax
  835.                   add    ecx, eax
  836.                   add    ecx, eax
  837.           // and now SetBackgroundPixel
  838.                   mov    eax, 15
  839.                   mov    ebx, 2
  840.                   mov    edx, Color
  841.                   int    64
  842.                   pop    ebx
  843.           End;
  844. (* -------------------------------------------------------- *)
  845. {15.3}    Procedure DrawBackground; StdCall;
  846.           Asm
  847.                   push   ebx
  848.                   mov    eax, 15
  849.                   mov    ebx, 3
  850.                   int    64
  851.                   pop    ebx
  852.           End;
  853. (* -------------------------------------------------------- *)
  854. {15.4}    Procedure SetBackgroundDrawMode(DrawMode: Dword); StdCall;
  855.           Asm
  856.                   push   ebx
  857.                   mov    eax, 15
  858.                   mov    ebx, 4
  859.                   mov    ecx, DrawMode
  860.                   int    64
  861.                   pop    ebx
  862.           End;
  863. (* -------------------------------------------------------- *)
  864. {15.5}    Procedure DrawBackgroundImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  865.           Asm
  866.                   push   ebx
  867.                   push   esi
  868.           // at first need to know Background.Width
  869.                   mov    eax, 39
  870.                   mov    ebx, 1
  871.                   int    64
  872.           // at now eax = (Width << 16) | Height
  873.           // need to make edx = (X + Y * Background.Width) * 3
  874.                   shr    eax, 16
  875.                   mul    Y
  876.                   add    eax, X
  877.                   mov    edx, eax
  878.                   add    edx, eax
  879.                   add    edx, eax
  880.           // need to make esi = Width * Height * 3
  881.                   mov    eax, Width
  882.                   mul    Height
  883.                   mov    esi, eax
  884.                   add    esi, eax
  885.                   add    esi, eax
  886.           // and now DrawBackgroundImage
  887.                   mov    eax, 15
  888.                   mov    ebx, 5
  889.                   mov    ecx, Image
  890.                   int    64
  891.                   pop    esi
  892.                   pop    ebx
  893.           End;
  894. (* -------------------------------------------------------- *)
  895. {15.6}    Function  MapBackground: Pointer; StdCall;
  896.           Asm
  897.                   push   ebx
  898.                   mov    eax, 15
  899.                   mov    ebx, 6
  900.                   int    64
  901.                   pop    ebx
  902.           End;
  903. (* -------------------------------------------------------- *)
  904. {15.7}    Function  UnMapBackground(Background: Pointer): Integer; StdCall;
  905.           Asm
  906.                   push   ebx
  907.                   mov    eax, 15
  908.                   mov    ebx, 7
  909.                   mov    ecx, Background
  910.                   int    64
  911.                   pop    ebx
  912.           End;
  913. (* -------------------------------------------------------- *)
  914. {15.8}    Function  GetLastDrawnBackgroundRect: TRect; StdCall;
  915.           Asm
  916.                   push   ebx
  917.                   push   edi
  918.                   mov    edi, eax
  919.                   mov    eax, 15
  920.                   mov    ebx, 8
  921.                   int    64
  922.                   movzx  edx, ax
  923.                   movzx  ecx, bx
  924.                   shr    eax, 16
  925.                   shr    ebx, 16
  926.                   mov    [edi].TRect.Left, eax
  927.                   mov    [edi].TRect.Right, edx
  928.                   mov    [edi].TRect.Top, ebx
  929.                   mov    [edi].TRect.Bottom, ecx
  930.                   pop    edi
  931.                   pop    ebx
  932.           End;
  933. (* -------------------------------------------------------- *)
  934. {15.9}    Procedure UpdateBackgroundRect(Left, Top, Right, Bottom: Integer); StdCall;
  935.           Asm
  936.                   push   ebx
  937.                   mov    eax, 15
  938.                   mov    ebx, 9
  939.                   mov    ecx, Left
  940.                   mov    edx, Top
  941.                   shl    ecx, 16
  942.                   shl    edx, 16
  943.                   or     ecx, Right
  944.                   or     edx, Bottom
  945.                   int    64
  946.                   pop    ebx
  947.           End;
  948. (* -------------------------------------------------------- *)
  949. {16}      Function  FlushFloppyCache(FloppyNumber: Dword): Dword; StdCall;
  950.           Asm
  951.                   push   ebx
  952.                   mov    eax, 15
  953.                   mov    ebx, FloppyNumber
  954.                   int    64
  955.                   pop    ebx
  956.           End;
  957. (* -------------------------------------------------------- *)
  958. {17}      Function  GetButton: TButtonInput; StdCall;
  959.           Asm
  960.                   mov    eax, 17
  961.                   int    64
  962.           End;
  963. (* -------------------------------------------------------- *)
  964. {18.1}    Procedure DeactivateWindow(Slot: Dword); StdCall;
  965.           Asm
  966.                   push   ebx
  967.                   mov    eax, 18
  968.                   mov    ebx, 1
  969.                   mov    ecx, Slot
  970.                   int    64
  971.                   pop    ebx
  972.           End;
  973. (* -------------------------------------------------------- *)
  974. {18.2}    Procedure ThreadTerminateBySlot(Slot: Dword); StdCall;
  975.           Asm
  976.                   push   ebx
  977.                   mov    eax, 18
  978.                   mov    ebx, 2
  979.                   mov    ecx, Slot
  980.                   int    64
  981.                   pop    ebx
  982.           End;
  983. (* -------------------------------------------------------- *)
  984. {18.3}    Procedure ActivateWindow(Slot: Dword); StdCall;
  985.           Asm
  986.                   push   ebx
  987.                   mov    eax, 18
  988.                   mov    ebx, 3
  989.                   mov    ecx, Slot
  990.                   int    64
  991.                   pop    ebx
  992.           End;
  993. (* -------------------------------------------------------- *)
  994. {18.4}    Function  GetIdleTime: Dword; StdCall;
  995.           Asm
  996.                   push   ebx
  997.                   mov    eax, 18
  998.                   mov    ebx, 4
  999.                   int    64
  1000.                   pop    ebx
  1001.           End;
  1002. (* -------------------------------------------------------- *)
  1003. {18.5}    Function  GetCPUClock: Dword; StdCall;
  1004.           Asm
  1005.                   push   ebx
  1006.                   mov    eax, 18
  1007.                   mov    ebx, 5
  1008.                   int    64
  1009.                   pop    ebx
  1010.           End;
  1011. (* -------------------------------------------------------- *)
  1012. {18.6}    Function  SaveRamDisk(Path: PChar): Dword; StdCall;
  1013.           Asm
  1014.                   push   ebx
  1015.                   mov    eax, 18
  1016.                   mov    ebx, 1
  1017.                   mov    ecx, Path
  1018.                   int    64
  1019.                   pop    ebx
  1020.           End;
  1021. (* -------------------------------------------------------- *)
  1022. {18.7}    Function  GetActiveWindow: Dword; StdCall;
  1023.           Asm
  1024.                   push   ebx
  1025.                   mov    eax, 18
  1026.                   mov    ebx, 7
  1027.                   int    64
  1028.                   pop    ebx
  1029.           End;
  1030. (* -------------------------------------------------------- *)
  1031. {18.8.1}  Function  GetSpeakerState: Integer; StdCall;
  1032.           Asm
  1033.                   push   ebx
  1034.                   mov    eax, 18
  1035.                   mov    ebx, 8
  1036.                   mov    ecx, 1
  1037.                   int    64
  1038.                   pop    ebx
  1039.           End;
  1040. (* -------------------------------------------------------- *)
  1041. {18.8.2}  Procedure SwitchSpeakerState; StdCall;
  1042.           Asm
  1043.                   push   ebx
  1044.                   mov    eax, 18
  1045.                   mov    ebx, 8
  1046.                   mov    ecx, 2
  1047.                   int    64
  1048.                   pop    ebx
  1049.           End;
  1050. (* -------------------------------------------------------- *)
  1051. {18.9}    Function  SystemShutdown(Param: Dword): Integer; StdCall;
  1052.           Asm
  1053.                   push   ebx
  1054.                   mov    eax, 18
  1055.                   mov    ebx, 9
  1056.                   mov    ecx, Param
  1057.                   int    64
  1058.                   pop    ebx
  1059.           End;
  1060. (* -------------------------------------------------------- *)
  1061. {18.10}   Procedure MinimizeActiveWindow; StdCall;
  1062.           Asm
  1063.                   push   ebx
  1064.                   mov    eax, 18
  1065.                   mov    ebx, 10
  1066.                   int    64
  1067.                   pop    ebx
  1068.           End;
  1069. (* -------------------------------------------------------- *)
  1070. {18.11}   Procedure GetDiskSystemInfo(Var Buffer); StdCall;
  1071.           Asm
  1072.                   push   ebx
  1073.                   mov    eax, 18
  1074.                   mov    ebx, 11
  1075.                   mov    ecx, Buffer
  1076.                   int    64
  1077.                   pop    ebx
  1078.           End;
  1079. (* -------------------------------------------------------- *)
  1080. {18.12}   {UNDEFINED}
  1081. (* -------------------------------------------------------- *)
  1082. {18.13}   Procedure GetKernelVersion(Var Buffer: TKernelVersion); StdCall;
  1083.           Asm
  1084.                   push   ebx
  1085.                   mov    eax, 18
  1086.                   mov    ebx, 13
  1087.                   mov    ecx, Buffer
  1088.                   int    64
  1089.                   pop    ebx
  1090.           End;
  1091. (* -------------------------------------------------------- *)
  1092. {18.14}   Function  WaitRetrace: Integer; StdCall;
  1093.           Asm
  1094.                   push   ebx
  1095.                   mov    eax, 18
  1096.                   mov    ebx, 14
  1097.                   int    64
  1098.                   pop    ebx
  1099.           End;
  1100. (* -------------------------------------------------------- *)
  1101. {18.15}   Function  CenterMousePointer: Integer; StdCall;
  1102.           Asm
  1103.                   push   ebx
  1104.                   mov    eax, 18
  1105.                   mov    ebx, 15
  1106.                   int    64
  1107.                   pop    ebx
  1108.           End;
  1109. (* -------------------------------------------------------- *)
  1110. {18.16}   Function  GetFreeMemory: Dword; StdCall;
  1111.           Asm
  1112.                   push   ebx
  1113.                   mov    eax, 18
  1114.                   mov    ebx, 16
  1115.                   int    64
  1116.                   pop    ebx
  1117.           End;
  1118. (* -------------------------------------------------------- *)
  1119. {18.17}   Function  GetAvailableMemory: Dword; StdCall;
  1120.           Asm
  1121.                   push   ebx
  1122.                   mov    eax, 18
  1123.                   mov    ebx, 17
  1124.                   int    64
  1125.                   pop    ebx
  1126.           End;
  1127. (* -------------------------------------------------------- *)
  1128. {18.18}   Function  ThreadTerminateById(ID: Dword): Integer; StdCall;
  1129.           Asm
  1130.                   push   ebx
  1131.                   mov    eax, 18
  1132.                   mov    ebx, 18
  1133.                   mov    ecx, ID
  1134.                   int    64
  1135.                   pop    ebx
  1136.           End;
  1137. (* -------------------------------------------------------- *)
  1138. {18.19.0} Function  GetMouseSpeed: Dword; StdCall;
  1139.           Asm
  1140.                   push   ebx
  1141.                   mov    eax, 18
  1142.                   mov    ebx, 19
  1143.                   mov    ecx, 0
  1144.                   int    64
  1145.                   pop    ebx
  1146.           End;
  1147. (* -------------------------------------------------------- *)
  1148. {18.19.1} Procedure SetMouseSpeed(Speed: Dword); StdCall;
  1149.           Asm
  1150.                   push   ebx
  1151.                   mov    eax, 18
  1152.                   mov    ebx, 19
  1153.                   mov    ecx, 1
  1154.                   mov    edx, Speed
  1155.                   int    64
  1156.                   pop    ebx
  1157.           End;
  1158. (* -------------------------------------------------------- *)
  1159. {18.19.2} Function  GetMouseSensitivity: Dword; StdCall;
  1160.           Asm
  1161.                   push   ebx
  1162.                   mov    eax, 18
  1163.                   mov    ebx, 19
  1164.                   mov    ecx, 2
  1165.                   int    64
  1166.                   pop    ebx
  1167.           End;
  1168. (* -------------------------------------------------------- *)
  1169. {18.19.3} Procedure SetMouseSensitivity(Sensitivity: Dword); StdCall;
  1170.           Asm
  1171.                   push   ebx
  1172.                   mov    eax, 18
  1173.                   mov    ebx, 19
  1174.                   mov    ecx, 3
  1175.                   mov    edx, Sensitivity
  1176.                   int    64
  1177.                   pop    ebx
  1178.           End;
  1179. (* -------------------------------------------------------- *)
  1180. {18.19.4} Procedure SetMousePos(X, Y: Integer); StdCall;
  1181.           Asm
  1182.                   push   ebx
  1183.                   mov    eax, 18
  1184.                   mov    ebx, 19
  1185.                   mov    ecx, 4
  1186.                   mov    edx, X
  1187.                   shl    edx, 16
  1188.                   or     edx, Y
  1189.                   int    64
  1190.                   pop    ebx
  1191.           End;
  1192. (* -------------------------------------------------------- *)
  1193. {18.19.5} Procedure SetMouseButtons(State: Dword); StdCall;
  1194.           Asm
  1195.                   push   ebx
  1196.                   mov    eax, 18
  1197.                   mov    ebx, 19
  1198.                   mov    ecx, 5
  1199.                   mov    edx, State
  1200.                   int    64
  1201.                   pop    ebx
  1202.           End;
  1203. (* -------------------------------------------------------- *)
  1204. {18.19.6} Function  GetDoubleClickTime: Dword; StdCall;
  1205.           Asm
  1206.                   push   ebx
  1207.                   mov    eax, 18
  1208.                   mov    ebx, 19
  1209.                   mov    ecx, 6
  1210.                   int    64
  1211.                   pop    ebx
  1212.           End;
  1213. (* -------------------------------------------------------- *)
  1214. {18.19.7} Procedure SetDoubleClickTime(Time: Dword); StdCall;
  1215.           Asm
  1216.                   push   ebx
  1217.                   mov    eax, 18
  1218.                   mov    ebx, 19
  1219.                   mov    ecx, 7
  1220.                   mov    edx, Time
  1221.                   int    64
  1222.                   pop    ebx
  1223.           End;
  1224. (* -------------------------------------------------------- *)
  1225. {18.20}   Function  GetRAMInfo(Var Buffer: TRAMInfo): Integer; StdCall;
  1226.           Asm
  1227.                   push   ebx
  1228.                   mov    eax, 18
  1229.                   mov    ebx, 20
  1230.                   mov    ecx, Buffer
  1231.                   int    64
  1232.                   pop    ebx
  1233.           End;
  1234. (* -------------------------------------------------------- *)
  1235. {18.21}   Function  GetSlotById(ID: Dword): Dword; StdCall;
  1236.           Asm
  1237.                   push   ebx
  1238.                   mov    eax, 18
  1239.                   mov    ebx, 21
  1240.                   mov    ecx, ID
  1241.                   int    64
  1242.                   pop    ebx
  1243.           End;
  1244. (* -------------------------------------------------------- *)
  1245. {18.22.0} Function  MinimizeWindowBySlot(Slot: Dword): Integer; StdCall;
  1246.           Asm
  1247.                   push   ebx
  1248.                   mov    eax, 18
  1249.                   mov    ebx, 22
  1250.                   mov    ecx, 0
  1251.                   mov    edx, Slot
  1252.                   int    64
  1253.                   pop    ebx
  1254.           End;
  1255. (* -------------------------------------------------------- *)
  1256. {18.22.1} Function  MinimizeWindowByID(ID: Dword): Integer; StdCall;
  1257.           Asm
  1258.                   push   ebx
  1259.                   mov    eax, 18
  1260.                   mov    ebx, 22
  1261.                   mov    ecx, 1
  1262.                   mov    edx, ID
  1263.                   int    64
  1264.                   pop    ebx
  1265.           End;
  1266. (* -------------------------------------------------------- *)
  1267. {18.22.2} Function  RestoreWindowBySlot(Slot: Dword): Integer; StdCall;
  1268.           Asm
  1269.                   push   ebx
  1270.                   mov    eax, 18
  1271.                   mov    ebx, 22
  1272.                   mov    ecx, 2
  1273.                   mov    edx, Slot
  1274.                   int    64
  1275.                   pop    ebx
  1276.           End;
  1277. (* -------------------------------------------------------- *)
  1278. {18.22.3} Function  RestoreWindowByID(ID: Dword): Integer; StdCall;
  1279.           Asm
  1280.                   push   ebx
  1281.                   mov    eax, 18
  1282.                   mov    ebx, 22
  1283.                   mov    ecx, 3
  1284.                   mov    edx, ID
  1285.                   int    64
  1286.                   pop    ebx
  1287.           End;
  1288. (* -------------------------------------------------------- *)
  1289. {18.23}   Function  MinimizeAllWindows: Dword; StdCall;
  1290.           Asm
  1291.                   push   ebx
  1292.                   mov    eax, 18
  1293.                   mov    ebx, 23
  1294.                   int    64
  1295.                   pop    ebx
  1296.           End;
  1297. (* -------------------------------------------------------- *)
  1298. {18.24}   Procedure SetScreenLimits(Width, Height: Dword); StdCall;
  1299.           Asm
  1300.                   push   ebx
  1301.                   mov    eax, 18
  1302.                   mov    ebx, 24
  1303.                   mov    ecx, Width
  1304.                   mov    edx, Height
  1305.                   int    64
  1306.                   pop    ebx
  1307.           End;
  1308. (* -------------------------------------------------------- *)
  1309. {18.25.1} Function  GetWindowZOrder(ID: Dword): Dword; StdCall;
  1310.           Asm
  1311.                   push   ebx
  1312.                   mov    eax, 18
  1313.                   mov    ebx, 25
  1314.                   mov    ecx, 1
  1315.                   mov    edx, ID
  1316.                   int    64
  1317.                   pop    ebx
  1318.           End;
  1319. (* -------------------------------------------------------- *)
  1320. {18.25.2} Function  SetWindowZOrder(ID, ZOrder: Dword): Integer; StdCall;
  1321.           Asm
  1322.                   push   ebx
  1323.                   push   esi
  1324.                   mov    eax, 18
  1325.                   mov    ebx, 25
  1326.                   mov    ecx, 2
  1327.                   mov    edx, ID
  1328.                   mov    esi, ZOrder
  1329.                   int    64
  1330.                   pop    esi
  1331.                   pop    ebx
  1332.           End;
  1333. (* -------------------------------------------------------- *)
  1334. {19}      {UNDEFINED}
  1335. (* -------------------------------------------------------- *)
  1336. {20.1}    Function  ResetMidi: Integer; StdCall;
  1337.           Asm
  1338.                   push   ebx
  1339.                   mov    eax, 20
  1340.                   mov    ebx, 1
  1341.                   int    64
  1342.                   pop    ebx
  1343.           End;
  1344. (* -------------------------------------------------------- *)
  1345. {20.2}    Function  OutputMidi(Data: Byte): Integer; StdCall;
  1346.           Asm
  1347.                   push   ebx
  1348.                   mov    eax, 20
  1349.                   mov    ebx, 2
  1350.                   mov    cl, Data
  1351.                   int    64
  1352.                   pop    ebx
  1353.           End;
  1354. (* -------------------------------------------------------- *)
  1355. {21.1}    Function  SetMidiBase(Port: Dword): Integer; StdCall;
  1356.           Asm
  1357.                   push   ebx
  1358.                   mov    eax, 21
  1359.                   mov    ebx, 1
  1360.                   mov    ecx, Port
  1361.                   int    64
  1362.                   pop    ebx
  1363.           End;
  1364. (* -------------------------------------------------------- *)
  1365. {21.2}    Function  SetKeyboardLayout(Flags: Dword; Var Table: TKeyboardLayout): Integer; StdCall;
  1366.           Asm
  1367.                   push   ebx
  1368.                   mov    eax, 21
  1369.                   mov    ebx, 2
  1370.                   mov    ecx, Flags
  1371.                   mov    edx, Table
  1372.                   int    64
  1373.                   pop    ebx
  1374.           End;
  1375. (* -------------------------------------------------------- *)
  1376. {21.2}    Function  SetKeyboardLayoutCountry(Country: Dword): Integer; StdCall;
  1377.           Asm
  1378.                   push   ebx
  1379.                   mov    eax, 21
  1380.                   mov    ebx, 2
  1381.                   mov    ecx, 9
  1382.                   mov    edx, Country
  1383.                   int    64
  1384.                   pop    ebx
  1385.           End;
  1386. (* -------------------------------------------------------- *)
  1387. {21.3}    {UNDEFINED}
  1388. (* -------------------------------------------------------- *)
  1389. {21.4}    {UNDEFINED}
  1390. (* -------------------------------------------------------- *)
  1391. {21.5}    Function  SetSystemLanguage(SystemLanguage: Dword): Integer; StdCall;
  1392.           Asm
  1393.                   push   ebx
  1394.                   mov    eax, 21
  1395.                   mov    ebx, 5
  1396.                   mov    ecx, SystemLanguage
  1397.                   int    64
  1398.                   pop    ebx
  1399.           End;
  1400. (* -------------------------------------------------------- *)
  1401. {21.6}    {UNDEFINED}
  1402. (* -------------------------------------------------------- *)
  1403. {21.7}    {UNDEFINED}
  1404. (* -------------------------------------------------------- *)
  1405. {21.8}    {UNDEFINED}
  1406. (* -------------------------------------------------------- *)
  1407. {21.9}    {UNDEFINED}
  1408. (* -------------------------------------------------------- *)
  1409. {21.10}   {UNDEFINED}
  1410. (* -------------------------------------------------------- *)
  1411. {21.11}   Function  SetHDAccess(Value: Dword): Integer; StdCall;
  1412.           Asm
  1413.                   push   ebx
  1414.                   mov    eax, 21
  1415.                   mov    ebx, 11
  1416.                   mov    ecx, Value
  1417.                   int    64
  1418.                   pop    ebx
  1419.           End;
  1420. (* -------------------------------------------------------- *)
  1421. {21.12}   Function  SetPCIAccess(Value: Dword): Integer; StdCall;
  1422.           Asm
  1423.                   push   ebx
  1424.                   mov    eax, 21
  1425.                   mov    ebx, 12
  1426.                   mov    ecx, Value
  1427.                   int    64
  1428.                   pop    ebx
  1429.           End;
  1430. (* -------------------------------------------------------- *)
  1431. {22.0}    Function  SetSystemTime(Time: TSystemTime): Integer; StdCall;
  1432.           Asm
  1433.                   push   ebx
  1434.                   mov    eax, 22
  1435.                   mov    ebx, 0
  1436.                   mov    ecx, Time
  1437.                   int    64
  1438.                   pop    ebx
  1439.           End;
  1440. (* -------------------------------------------------------- *)
  1441. {22.1}    Function  SetSystemDate(Date: TSystemDate): Integer; StdCall;
  1442.           Asm
  1443.                   push   ebx
  1444.                   mov    eax, 22
  1445.                   mov    ebx, 1
  1446.                   mov    ecx, Date
  1447.                   int    64
  1448.                   pop    ebx
  1449.           End;
  1450. (* -------------------------------------------------------- *)
  1451. {22.2}    Function  SetDayOfWeek(DayOfWeek: Dword): Integer; StdCall;
  1452.           Asm
  1453.                   push   ebx
  1454.                   mov    eax, 22
  1455.                   mov    ebx, 2
  1456.                   mov    ecx, DayOfWeek
  1457.                   int    64
  1458.                   pop    ebx
  1459.           End;
  1460. (* -------------------------------------------------------- *)
  1461. {22.3}    Function  SetAlarm(Time: TSystemTime): Integer; StdCall;
  1462.           Asm
  1463.                   push   ebx
  1464.                   mov    eax, 22
  1465.                   mov    ebx, 3
  1466.                   mov    ecx, Time
  1467.                   int    64
  1468.                   pop    ebx
  1469.           End;
  1470. (* -------------------------------------------------------- *)
  1471. {23}      Function  WaitEventByTime(Time: Dword): Dword; StdCall;
  1472.           Asm
  1473.                   push   ebx
  1474.                   mov    eax, 23
  1475.                   mov    ebx, Time
  1476.                   int    64
  1477.                   pop    ebx
  1478.           End;
  1479. (* -------------------------------------------------------- *)
  1480. {24.4}    Procedure OpenCDTray(Drive: Dword); StdCall;
  1481.           Asm
  1482.                   push   ebx
  1483.                   mov    eax, 24
  1484.                   mov    ebx, 4
  1485.                   mov    ecx, Drive
  1486.                   int    64
  1487.                   pop    ebx
  1488.           End;
  1489. (* -------------------------------------------------------- *)
  1490. {24.5}    Procedure CloseCDTray(Drive: Dword); StdCall;
  1491.           Asm
  1492.                   push   ebx
  1493.                   mov    eax, 24
  1494.                   mov    ebx, 5
  1495.                   mov    ecx, Drive
  1496.                   int    64
  1497.                   pop    ebx
  1498.           End;
  1499. (* -------------------------------------------------------- *)
  1500. {25}      Procedure DrawBackgroundLayerImage(Const Image; X, Y: Integer; Width, Height: Dword); StdCall;
  1501.           Asm
  1502.                   push   ebx
  1503.                   mov    eax, 25
  1504.                   mov    ebx, Image
  1505.                   mov    ecx, Width
  1506.                   mov    edx, X
  1507.                   shl    ecx, 16
  1508.                   shl    edx, 16
  1509.                   or     ecx, Height
  1510.                   or     edx, Y
  1511.                   int    64
  1512.                   pop    ebx
  1513.           End;
  1514. (* -------------------------------------------------------- *)
  1515. {26.1}    Function  GetMidiBase: Dword; StdCall;
  1516.           Asm
  1517.                   push   ebx
  1518.                   mov    eax, 26
  1519.                   mov    ebx, 1
  1520.                   int    64
  1521.                   pop    ebx
  1522.           End;
  1523. (* -------------------------------------------------------- *)
  1524. {26.2}    Procedure GetKeyboardLayout(Flags: Dword; Var Table: TKeyboardLayout); StdCall;
  1525.           Asm
  1526.                   push   ebx
  1527.                   mov    eax, 26
  1528.                   mov    ebx, 2
  1529.                   mov    ecx, Flags
  1530.                   mov    edx, Table
  1531.                   int    64
  1532.                   pop    ebx
  1533.           End;
  1534. (* -------------------------------------------------------- *)
  1535. {26.2}    Function  GetKeyboardLayoutCountry: Dword; StdCall;
  1536.           Asm
  1537.                   push   ebx
  1538.                   mov    eax, 26
  1539.                   mov    ebx, 2
  1540.                   mov    ecx, 9
  1541.                   int    64
  1542.                   pop    ebx
  1543.           End;
  1544. (* -------------------------------------------------------- *)
  1545. {26.3}    {UNDEFINED}
  1546. (* -------------------------------------------------------- *)
  1547. {26.4}    {UNDEFINED}
  1548. (* -------------------------------------------------------- *)
  1549. {26.5}    Function  GetSystemLanguage: Dword; StdCall;
  1550.           Asm
  1551.                   push   ebx
  1552.                   mov    eax, 26
  1553.                   mov    ebx, 5
  1554.                   int    64
  1555.                   pop    ebx
  1556.           End;
  1557. (* -------------------------------------------------------- *)
  1558. {26.6}    {UNDEFINED}
  1559. (* -------------------------------------------------------- *)
  1560. {26.7}    {UNDEFINED}
  1561. (* -------------------------------------------------------- *)
  1562. {26.8}    {UNDEFINED}
  1563. (* -------------------------------------------------------- *)
  1564. {26.9}    Function  GetTickCount: Dword; StdCall;
  1565.           Asm
  1566.                   push   ebx
  1567.                   mov    eax, 26
  1568.                   mov    ebx, 9
  1569.                   int    64
  1570.                   pop    ebx
  1571.           End;
  1572. (* -------------------------------------------------------- *)
  1573. {26.10}   Function  GetTickCount64: Qword; StdCall;
  1574.           Asm
  1575.                   push   ebx
  1576.                   mov    eax, 26
  1577.                   mov    ebx, 10
  1578.                   int    64
  1579.                   pop    ebx
  1580.           End;
  1581. (* -------------------------------------------------------- *)
  1582. {26.11}   Function  IsHDAccessAllowed: Dword; StdCall;
  1583.           Asm
  1584.                   push   ebx
  1585.                   mov    eax, 26
  1586.                   mov    ebx, 11
  1587.                   int    64
  1588.                   pop    ebx
  1589.           End;
  1590. (* -------------------------------------------------------- *)
  1591. {26.12}   Function  IsPCIAccessAllowed: Dword; StdCall;
  1592.           Asm
  1593.                   push   ebx
  1594.                   mov    eax, 26
  1595.                   mov    ebx, 12
  1596.                   int    64
  1597.                   pop    ebx
  1598.           End;
  1599. (* -------------------------------------------------------- *)
  1600. {27}      {UNDEFINED}
  1601. (* -------------------------------------------------------- *)
  1602. {28}      {UNDEFINED}
  1603. (* -------------------------------------------------------- *)
  1604. {29}      Function  GetSystemDate: TSystemDate; StdCall;
  1605.           Asm
  1606.                   mov    eax, 29
  1607.                   int    64
  1608.           End;
  1609. (* -------------------------------------------------------- *)
  1610. {30.1}    Procedure SetCurrentDirectory(Path: PChar); StdCall;
  1611.           Asm
  1612.                   push   ebx
  1613.                   mov    eax, 30
  1614.                   mov    ebx, 1
  1615.                   mov    ecx, Path
  1616.                   int    64
  1617.                   pop    ebx
  1618.           End;
  1619. (* -------------------------------------------------------- *)
  1620. {30.2}    Function  GetCurrentDirectory(Buffer: PChar; Count: Dword): Dword; StdCall;
  1621.           Asm
  1622.                   push   ebx
  1623.                   mov    eax, 30
  1624.                   mov    ebx, 2
  1625.                   mov    ecx, Buffer
  1626.                   mov    edx, Count
  1627.                   int    64
  1628.                   pop    ebx
  1629.           End;
  1630. (* -------------------------------------------------------- *)
  1631. {31}      {UNDEFINED}
  1632. (* -------------------------------------------------------- *)
  1633. {32}      {UNDEFINED}
  1634. (* -------------------------------------------------------- *)
  1635. {33}      {UNDEFINED}
  1636. (* -------------------------------------------------------- *)
  1637. {34}      Function  GetPointOwner(X, Y: Integer): Dword; StdCall;
  1638.           Asm
  1639.                   push   ebx
  1640.                   mov    eax, 34
  1641.                   mov    ebx, X
  1642.                   mov    ecx, Y
  1643.                   int    64
  1644.                   pop    ebx
  1645.           End;
  1646. (* -------------------------------------------------------- *)
  1647. {35}      Function  GetPixel(X, Y: Integer): Dword; StdCall;
  1648.           Asm
  1649.                   push   ebx
  1650.           // at first need to know Screen.Width
  1651.                   mov    eax, 61
  1652.                   mov    ebx, 1
  1653.                   int    64
  1654.           // at now eax = (Width << 16) | Height
  1655.           // need to make ebx = Y * Screen.Width + X
  1656.                   shr    eax, 16
  1657.                   mul    Y
  1658.                   add    eax, X
  1659.                   mov    ebx, eax
  1660.           // and now GetPixel
  1661.                   mov    eax, 35
  1662.                   int    64
  1663.                   pop    ebx
  1664.           End;
  1665. (* -------------------------------------------------------- *)
  1666. {36}      Procedure GetScreenImage(Var Buffer; X, Y: Integer; Width, Height: Dword); StdCall;
  1667.           Asm
  1668.                   push   ebx
  1669.                   mov    eax, 36
  1670.                   mov    ebx, Buffer
  1671.                   mov    ecx, Width
  1672.                   mov    edx, X
  1673.                   shl    ecx, 16
  1674.                   shl    edx, 16
  1675.                   or     ecx, Height
  1676.                   or     edx, Y
  1677.                   int    64
  1678.                   pop    ebx
  1679.           End;
  1680. (* -------------------------------------------------------- *)
  1681. {37.0}    Function  GetMousePos: TPoint; StdCall;
  1682.           Asm
  1683.                   push   ebx
  1684.                   mov    eax, 37
  1685.                   mov    ebx, 0
  1686.                   int    64
  1687.                   pop    ebx
  1688.           End;
  1689. (* -------------------------------------------------------- *)
  1690. {37.1}    Function  GetWindowMousePos: TPoint; StdCall;
  1691.           Asm
  1692.                   push   ebx
  1693.                   mov    eax, 37
  1694.                   mov    ebx, 1
  1695.                   int    64
  1696.                   pop    ebx
  1697.           End;
  1698. (* -------------------------------------------------------- *)
  1699. {37.2}    Function  GetMouseButtons: Dword; StdCall;
  1700.           Asm
  1701.                   push   ebx
  1702.                   mov    eax, 37
  1703.                   mov    ebx, 2
  1704.                   int    64
  1705.                   pop    ebx
  1706.           End;
  1707. (* -------------------------------------------------------- *)
  1708. {37.3}    Function  GetMouseEvents: Dword; StdCall;
  1709.           Asm
  1710.                   push   ebx
  1711.                   mov    eax, 37
  1712.                   mov    ebx, 3
  1713.                   int    64
  1714.                   pop    ebx
  1715.           End;
  1716. (* -------------------------------------------------------- *)
  1717. {37.4}    Function  LoadCursorFromFile(Path: PChar): Dword; StdCall;
  1718.           Asm
  1719.                   push   ebx
  1720.                   mov    eax, 37
  1721.                   mov    ebx, 4
  1722.                   mov    ecx, Path
  1723.                   mov    edx, 0
  1724.                   int    64
  1725.                   pop    ebx
  1726.           End;
  1727. (* -------------------------------------------------------- *)
  1728. {37.4}    Function  LoadCursorFromMemory(Const Buffer): Dword; StdCall;
  1729.           Asm
  1730.                   push   ebx
  1731.                   mov    eax, 37
  1732.                   mov    ebx, 4
  1733.                   mov    ecx, Buffer
  1734.                   mov    edx, 1
  1735.                   int    64
  1736.                   pop    ebx
  1737.           End;
  1738. (* -------------------------------------------------------- *)
  1739. {37.4}    Function  LoadCursorIndirect(Const Buffer; HotSpotX, HotSpotY: ShortInt): Dword; StdCall;
  1740.           Asm
  1741.                   push   ebx
  1742.                   mov    eax, 37
  1743.                   mov    ebx, 4
  1744.                   mov    ecx, Buffer
  1745.                   mov    dl, HotSpotY
  1746.                   mov    dh, HotSpotX
  1747.                   shl    edx, 16
  1748.                   or     edx, 2
  1749.                   int    64
  1750.                   pop    ebx
  1751.           End;
  1752. (* -------------------------------------------------------- *)
  1753. {37.5}    Function  SetCursor(Handle: Dword): Dword; StdCall;
  1754.           Asm
  1755.                   push   ebx
  1756.                   mov    eax, 37
  1757.                   mov    ebx, 5
  1758.                   mov    ecx, Handle
  1759.                   int    64
  1760.                   pop    ebx
  1761.           End;
  1762. (* -------------------------------------------------------- *)
  1763. {37.6}    Function  DeleteCursor(Handle: Dword): Dword; StdCall;
  1764.           Asm
  1765.                   push   ebx
  1766.                   mov    eax, 37
  1767.                   mov    ebx, 6
  1768.                   mov    ecx, Handle
  1769.                   int    64
  1770.                   pop    ebx
  1771.           End;
  1772. (* -------------------------------------------------------- *)
  1773. {37.7}    Function  GetMouseScroll: TPoint; StdCall;
  1774.           Asm
  1775.                   push   ebx
  1776.                   mov    eax, 37
  1777.                   mov    ebx, 7
  1778.                   int    64
  1779.                   pop    ebx
  1780.           End;
  1781. (* -------------------------------------------------------- *)
  1782. {38}      Procedure DrawLine(X1, Y1, X2, Y2: Integer; Color: Dword); StdCall;
  1783.           Asm
  1784.                   push   ebx
  1785.                   mov    eax, 38
  1786.                   mov    ebx, X1
  1787.                   mov    ecx, Y1
  1788.                   shl    ebx, 16
  1789.                   shl    ecx, 16
  1790.                   or     ebx, X2
  1791.                   or     ecx, Y2
  1792.                   mov    edx, Color
  1793.                   int    64
  1794.                   pop    ebx
  1795.           End;
  1796. (* -------------------------------------------------------- *)
  1797. {39.1}    Function  GetBackgroundSize: TSize; StdCall;
  1798.           Asm
  1799.                   push   ebx
  1800.                   mov    eax, 39
  1801.                   mov    ebx, 1
  1802.                   int    64
  1803.                   pop    ebx
  1804.           End;
  1805. (* -------------------------------------------------------- *)
  1806. {39.2}    Function  GetBackgroundPixel(X, Y: Integer): Dword; StdCall;
  1807.           Asm
  1808.                   push   ebx
  1809.           // at first need to know Background.Width
  1810.                   mov    eax, 39
  1811.                   mov    ebx, 1
  1812.                   int    64
  1813.           // at now eax = (Width << 16) | Height
  1814.           // need to make ecx = (X + Y * Background.Width) * 3
  1815.                   shr    eax, 16
  1816.                   mul    Y
  1817.                   add    eax, X
  1818.                   mov    ecx, eax
  1819.                   add    ecx, eax
  1820.                   add    ecx, eax
  1821.           // and now GetBackgroundPixel
  1822.                   mov    eax, 39
  1823.                   mov    ebx, 2
  1824.                   int    64
  1825.                   pop    ebx
  1826.           End;
  1827. (* -------------------------------------------------------- *)
  1828. {39.3}    {UNDEFINED}
  1829. (* -------------------------------------------------------- *)
  1830. {39.4}    Function  GetBackgroundDrawMode: Dword; StdCall;
  1831.           Asm
  1832.                   push   ebx
  1833.                   mov    eax, 39
  1834.                   mov    ebx, 4
  1835.                   int    64
  1836.                   pop    ebx
  1837.           End;
  1838. (* -------------------------------------------------------- *)
  1839. {40}      Function  SetEventMask(Mask: Dword): Dword; StdCall;
  1840.           Asm
  1841.                   push   ebx
  1842.                   mov    eax, 40
  1843.                   mov    ebx, Mask
  1844.                   int    64
  1845.                   pop    ebx
  1846.           End;
  1847. (* -------------------------------------------------------- *)
  1848. {41}      {UNDEFINED}
  1849. (* -------------------------------------------------------- *)
  1850. {42}      {UNDEFINED}
  1851. (* -------------------------------------------------------- *)
  1852. {43}      Function  InPort(Port: Dword; Var Data: Byte): Dword; StdCall;
  1853.           Asm
  1854.                   push   ebx
  1855.                   mov    eax, 43
  1856.                   mov    ecx, Port
  1857.                   or     ecx, $80000000
  1858.                   int    64
  1859.                   mov    ecx, Data
  1860.                   mov    [ecx], bl
  1861.                   pop    ebx
  1862.           End;
  1863. (* -------------------------------------------------------- *)
  1864. {43}      Function  OutPort(Port: Dword; Data: Byte): Dword; StdCall;
  1865.           Asm
  1866.                   push   ebx
  1867.                   mov    eax, 43
  1868.                   mov    bl, Data
  1869.                   mov    ecx, Port
  1870.                   int    64
  1871.                   pop    ebx
  1872.           End;
  1873. (* -------------------------------------------------------- *)
  1874. {44}      {UNDEFINED}
  1875. (* -------------------------------------------------------- *)
  1876. {45}      {UNDEFINED}
  1877. (* -------------------------------------------------------- *)
  1878. {46}      Function  ReservePorts(First, Last: Dword): Dword; StdCall;
  1879.           Asm
  1880.                   push   ebx
  1881.                   mov    eax, 46
  1882.                   mov    ebx, 0
  1883.                   mov    ecx, First
  1884.                   mov    edx, Last
  1885.                   int    64
  1886.                   pop    ebx
  1887.           End;
  1888. (* -------------------------------------------------------- *)
  1889. {46}      Function  FreePorts(First, Last: Dword): Dword; StdCall;
  1890.           Asm
  1891.                   push   ebx
  1892.                   mov    eax, 46
  1893.                   mov    ebx, 1
  1894.                   mov    ecx, First
  1895.                   mov    edx, Last
  1896.                   int    64
  1897.                   pop    ebx
  1898.           End;
  1899. (* -------------------------------------------------------- *)
  1900. {47}      {DrawNumber}
  1901. (* -------------------------------------------------------- *)
  1902. {48.0}    Procedure ApplyStyleSettings; StdCall;
  1903.           Asm
  1904.                   push   ebx
  1905.                   mov    eax, 48
  1906.                   mov    ebx, 0
  1907.                   int    64
  1908.                   pop    ebx
  1909.           End;
  1910. (* -------------------------------------------------------- *)
  1911. {48.1}    Procedure SetButtonStyle(ButtonStyle: Dword); StdCall;
  1912.           Asm
  1913.                   push   ebx
  1914.                   mov    eax, 48
  1915.                   mov    ebx, 1
  1916.                   mov    ecx, ButtonStyle
  1917.                   int    64
  1918.                   pop    ebx
  1919.           End;
  1920. (* -------------------------------------------------------- *)
  1921. {48.2}    Procedure SetStandardColors(Var ColorTable: TStandardColors; Size: Dword); StdCall;
  1922.           Asm
  1923.                   push   ebx
  1924.                   mov    eax, 48
  1925.                   mov    ebx, 2
  1926.                   mov    ecx, ColorTable
  1927.                   mov    edx, Size
  1928.                   int    64
  1929.                   pop    ebx
  1930.           End;
  1931. (* -------------------------------------------------------- *)
  1932. {48.3}    Procedure GetStandardColors(Var ColorTable: TStandardColors; Size: Dword); StdCall;
  1933.           Asm
  1934.                   push   ebx
  1935.                   mov    eax, 48
  1936.                   mov    ebx, 3
  1937.                   mov    ecx, ColorTable
  1938.                   mov    edx, Size
  1939.                   int    64
  1940.                   pop    ebx
  1941.           End;
  1942. (* -------------------------------------------------------- *)
  1943. {48.4}    Function  GetSkinHeight: Dword; StdCall;
  1944.           Asm
  1945.                   push   ebx
  1946.                   mov    eax, 48
  1947.                   mov    ebx, 4
  1948.                   int    64
  1949.                   pop    ebx
  1950.           End;
  1951. (* -------------------------------------------------------- *)
  1952. {48.5}    Function  GetScreenWorkingArea: TRect; StdCall;
  1953.           Asm
  1954.                   push   ebx
  1955.                   push   edi
  1956.                   mov    edi, eax
  1957.                   mov    eax, 48
  1958.                   mov    ebx, 5
  1959.                   int    64
  1960.                   movzx  edx, ax
  1961.                   movzx  ecx, bx
  1962.                   shr    eax, 16
  1963.                   shr    ebx, 16
  1964.                   mov    [edi].TRect.Left, eax
  1965.                   mov    [edi].TRect.Right, edx
  1966.                   mov    [edi].TRect.Top, ebx
  1967.                   mov    [edi].TRect.Bottom, ecx
  1968.                   pop    edi
  1969.                   pop    ebx
  1970.           End;
  1971. (* -------------------------------------------------------- *)
  1972. {48.6}    Procedure SetScreenWorkingArea(Left, Top, Right, Bottom: Integer); StdCall;
  1973.           Asm
  1974.                   push   ebx
  1975.                   mov    eax, 48
  1976.                   mov    ebx, 6
  1977.                   mov    ecx, Left
  1978.                   mov    edx, Top
  1979.                   shl    ecx, 16
  1980.                   shl    edx, 16
  1981.                   or     ecx, Right
  1982.                   or     edx, Bottom
  1983.                   int    64
  1984.                   pop    ebx
  1985.           End;
  1986. (* -------------------------------------------------------- *)
  1987. {48.7}    Function  GetSkinMargins: TRect; StdCall;
  1988.           Asm
  1989.                   push   ebx
  1990.                   push   edi
  1991.                   mov    edi, eax
  1992.                   mov    eax, 48
  1993.                   mov    ebx, 7
  1994.                   int    64
  1995.                   movzx  edx, ax
  1996.                   movzx  ecx, bx
  1997.                   shr    eax, 16
  1998.                   shr    ebx, 16
  1999.                   mov    [edi].TRect.Left, eax
  2000.                   mov    [edi].TRect.Right, edx
  2001.                   mov    [edi].TRect.Top, ebx
  2002.                   mov    [edi].TRect.Bottom, ecx
  2003.                   pop    edi
  2004.                   pop    ebx
  2005.           End;
  2006. (* -------------------------------------------------------- *)
  2007. {48.8}    Function  SetSkin(Path: PChar): Integer; StdCall;
  2008.           Asm
  2009.                   push   ebx
  2010.                   mov    eax, 48
  2011.                   mov    ebx, 8
  2012.                   mov    ecx, Path
  2013.                   int    64
  2014.                   pop    ebx
  2015.           End;
  2016. (* -------------------------------------------------------- *)
  2017. {48.9}    Function  GetFontSmoothing: Integer; StdCall;
  2018.           Asm
  2019.                   push   ebx
  2020.                   mov    eax, 48
  2021.                   mov    ebx, 9
  2022.                   int    64
  2023.                   pop    ebx
  2024.           End;
  2025. (* -------------------------------------------------------- *)
  2026. {48.10}   Procedure SetFontSmoothing(Smoothing: Integer); StdCall;
  2027.           Asm
  2028.                   push   ebx
  2029.                   mov    eax, 48
  2030.                   mov    ebx, 10
  2031.                   mov    ecx, Smoothing
  2032.                   int    64
  2033.                   pop    ebx
  2034.           End;
  2035. (* -------------------------------------------------------- *)
  2036. {48.11}   Function  GetFontHeight: Dword; StdCall;
  2037.           Asm
  2038.                   push   ebx
  2039.                   mov    eax, 48
  2040.                   mov    ebx, 11
  2041.                   int    64
  2042.                   pop    ebx
  2043.           End;
  2044. (* -------------------------------------------------------- *)
  2045. {48.12}   Procedure SetFontHeight(Height: Dword); StdCall;
  2046.           Asm
  2047.                   push   ebx
  2048.                   mov    eax, 48
  2049.                   mov    ebx, 12
  2050.                   mov    ecx, Height
  2051.                   int    64
  2052.                   pop    ebx
  2053.           End;
  2054. (* -------------------------------------------------------- *)
  2055. {49}      {Advanced Power Management}
  2056. (* -------------------------------------------------------- *)
  2057. {50.0}    Procedure SetWindowShape(Const Data); StdCall;
  2058.           Asm
  2059.                   push   ebx
  2060.                   mov    eax, 50
  2061.                   mov    ebx, 0
  2062.                   mov    ecx, Data
  2063.                   int    64
  2064.                   pop    ebx
  2065.           End;
  2066. (* -------------------------------------------------------- *)
  2067. {50.1}    Procedure SetWindowScale(Scale: Dword); StdCall;
  2068.           Asm
  2069.                   push   ebx
  2070.                   mov    eax, 50
  2071.                   mov    ebx, 1
  2072.                   mov    ecx, Scale
  2073.                   int    64
  2074.                   pop    ebx
  2075.           End;
  2076. (* -------------------------------------------------------- *)
  2077. {51.1}    Function  ThreadCreate(Entry, Stack: Pointer): Dword; StdCall;
  2078.           Asm
  2079.                   push   ebx
  2080.                   mov    eax, 51
  2081.                   mov    ebx, 1
  2082.                   mov    ecx, Entry
  2083.                   mov    edx, Stack
  2084.                   int    64
  2085.                   pop    ebx
  2086.           End;
  2087. (* -------------------------------------------------------- *)
  2088. {52}      {UNDEFINED}
  2089. (* -------------------------------------------------------- *)
  2090. {53}      {UNDEFINED}
  2091. (* -------------------------------------------------------- *)
  2092. {54.0}    Function  GetClipboardSlotCount: Integer; StdCall;
  2093.           Asm
  2094.                   push   ebx
  2095.                   mov    eax, 54
  2096.                   mov    ebx, 0
  2097.                   int    64
  2098.                   pop    ebx
  2099.           End;
  2100. (* -------------------------------------------------------- *)
  2101. {54.1}    Function  GetClipboardData(Slot: Dword): Pointer; StdCall;
  2102.           Asm
  2103.                   push   ebx
  2104.                   mov    eax, 54
  2105.                   mov    ebx, 1
  2106.                   mov    ecx, Slot
  2107.                   int    64
  2108.                   pop    ebx
  2109.           End;
  2110. (* -------------------------------------------------------- *)
  2111. {54.2}    Function  SetClipboardData(Const Src; Count: Dword): Integer; StdCall;
  2112.           Asm
  2113.                   push   ebx
  2114.                   mov    eax, 54
  2115.                   mov    ebx, 2
  2116.                   mov    ecx, Count
  2117.                   mov    edx, Src
  2118.                   int    64
  2119.                   pop    ebx
  2120.           End;
  2121. (* -------------------------------------------------------- *)
  2122. {54.3}    Function  DeleteClipboardLastSlot: Integer; StdCall;
  2123.           Asm
  2124.                   push   ebx
  2125.                   mov    eax, 54
  2126.                   mov    ebx, 3
  2127.                   int    64
  2128.                   pop    ebx
  2129.           End;
  2130. (* -------------------------------------------------------- *)
  2131. {54.4}    Function  ResetClipboard: Integer; StdCall;
  2132.           Asm
  2133.                   push   ebx
  2134.                   mov    eax, 54
  2135.                   mov    ebx, 4
  2136.                   int    64
  2137.                   pop    ebx
  2138.           End;
  2139. (* -------------------------------------------------------- *)
  2140. {55}      Function  SpeakerPlay(Const Data): Dword; StdCall;
  2141.           Asm
  2142.                   push   ebx
  2143.                   push   esi
  2144.                   mov    eax, 55
  2145.                   mov    ebx, 55
  2146.                   mov    esi, Data
  2147.                   int    64
  2148.                   pop    esi
  2149.                   pop    ebx
  2150.           End;
  2151. (* -------------------------------------------------------- *)
  2152. {56}      {UNDEFINED}
  2153. (* -------------------------------------------------------- *)
  2154. {57}      {PCI BIOS}
  2155. (* -------------------------------------------------------- *)
  2156. {58}      {UNDEFINED}
  2157. (* -------------------------------------------------------- *)
  2158. {59}      {UNDEFINED}
  2159. (* -------------------------------------------------------- *)
  2160. {60.1}    Function  IPCSetBuffer(Const Buffer: TIPCBuffer; Size: Dword): Integer; StdCall;
  2161.           Asm
  2162.                   push   ebx
  2163.                   mov    eax, 60
  2164.                   mov    ebx, 1
  2165.                   mov    ecx, Buffer
  2166.                   mov    edx, Size
  2167.                   int    64
  2168.                   pop    ebx
  2169.           End;
  2170. (* -------------------------------------------------------- *)
  2171. {60.2}    Function  IPCSendMessage(ID: Dword; Var Msg: TIPCMessage; Size: Dword): Integer; StdCall;
  2172.           Asm
  2173.                   push   ebx
  2174.                   push   esi
  2175.                   mov    eax, 60
  2176.                   mov    ebx, 2
  2177.                   mov    ecx, ID
  2178.                   mov    edx, Msg
  2179.                   mov    esi, Size
  2180.                   int    64
  2181.                   pop    esi
  2182.                   pop    ebx
  2183.           End;
  2184. (* -------------------------------------------------------- *)
  2185. {61.1}    Function  GetScreenSize: TSize; StdCall;
  2186.           Asm
  2187.                   push   ebx
  2188.                   mov    eax, 61
  2189.                   mov    ebx, 1
  2190.                   int    64
  2191.                   pop    ebx
  2192.           End;
  2193. (* -------------------------------------------------------- *)
  2194. {61.2}    Function  GetScreenBitsPerPixel: Dword; StdCall;
  2195.           Asm
  2196.                   push   ebx
  2197.                   mov    eax, 61
  2198.                   mov    ebx, 2
  2199.                   int    64
  2200.                   pop    ebx
  2201.           End;
  2202. (* -------------------------------------------------------- *)
  2203. {61.3}    Function  GetScreenBytesPerScanLine: Dword; StdCall;
  2204.           Asm
  2205.                   push   ebx
  2206.                   mov    eax, 61
  2207.                   mov    ebx, 3
  2208.                   int    64
  2209.                   pop    ebx
  2210.           End;
  2211. (* -------------------------------------------------------- *)
  2212. {62.0}    Function  GetPCIVersion: Dword; StdCall;
  2213.           Asm
  2214.                   push   ebx
  2215.                   mov    eax, 62
  2216.                   mov    bl, 0
  2217.                   int    64
  2218.                   pop    ebx
  2219.           End;
  2220. (* -------------------------------------------------------- *)
  2221. {62.1}    Function  GetLastPCIBus: Dword; StdCall;
  2222.           Asm
  2223.                   push   ebx
  2224.                   mov    eax, 62
  2225.                   mov    bl, 1
  2226.                   int    64
  2227.                   pop    ebx
  2228.           End;
  2229. (* -------------------------------------------------------- *)
  2230. {62.2}    Function  GetPCIAddressingMode: Dword; StdCall;
  2231.           Asm
  2232.                   push   ebx
  2233.                   mov    eax, 62
  2234.                   mov    bl, 2
  2235.                   int    64
  2236.                   pop    ebx
  2237.           End;
  2238. (* -------------------------------------------------------- *)
  2239. {62.3}    {UNDEFINED}
  2240. (* -------------------------------------------------------- *)
  2241. {62.4}    Function  ReadPCIByte(Bus, Device, Func, Reg: Byte): Byte; StdCall;
  2242.           Asm
  2243.                   push   ebx
  2244.                   mov    eax, 62
  2245.                   mov    bl, 4
  2246.                   mov    bh, Bus
  2247.                   mov    cl, Reg
  2248.                   mov    ch, Device
  2249.                   shl    ch, 3
  2250.                   or     ch, Func
  2251.                   int    64
  2252.                   pop    ebx
  2253.           End;
  2254. (* -------------------------------------------------------- *)
  2255. {62.5}    Function  ReadPCIWord(Bus, Device, Func, Reg: Byte): Word; StdCall;
  2256.           Asm
  2257.                   push   ebx
  2258.                   mov    eax, 62
  2259.                   mov    bl, 5
  2260.                   mov    bh, Bus
  2261.                   mov    cl, Reg
  2262.                   mov    ch, Device
  2263.                   shl    ch, 3
  2264.                   or     ch, Func
  2265.                   int    64
  2266.                   pop    ebx
  2267.           End;
  2268. (* -------------------------------------------------------- *)
  2269. {62.6}    Function  ReadPCIDword(Bus, Device, Func, Reg: Byte): Dword; StdCall;
  2270.           Asm
  2271.                   push   ebx
  2272.                   mov    eax, 62
  2273.                   mov    bl, 6
  2274.                   mov    bh, Bus
  2275.                   mov    cl, Reg
  2276.                   mov    ch, Device
  2277.                   shl    ch, 3
  2278.                   or     ch, Func
  2279.                   int    64
  2280.                   pop    ebx
  2281.           End;
  2282. (* -------------------------------------------------------- *)
  2283. {62.7}    {UNDEFINED}
  2284. (* -------------------------------------------------------- *)
  2285. {62.8}    Function  WritePCIByte(Bus, Device, Func, Reg: Byte; Data: Byte): Dword; StdCall;
  2286.           Asm
  2287.                   push   ebx
  2288.                   mov    eax, 62
  2289.                   mov    bl, 8
  2290.                   mov    bh, Bus
  2291.                   mov    cl, Reg
  2292.                   mov    ch, Device
  2293.                   shl    ch, 3
  2294.                   or     ch, Func
  2295.                   mov    dl, Data
  2296.                   int    64
  2297.                   pop    ebx
  2298.           End;
  2299. (* -------------------------------------------------------- *)
  2300. {62.9}    Function  WritePCIWord(Bus, Device, Func, Reg: Byte; Data: Word): Dword; StdCall;
  2301.           Asm
  2302.                   push   ebx
  2303.                   mov    eax, 62
  2304.                   mov    bl, 9
  2305.                   mov    bh, Bus
  2306.                   mov    cl, Reg
  2307.                   mov    ch, Device
  2308.                   shl    ch, 3
  2309.                   or     ch, Func
  2310.                   mov    dx, Data
  2311.                   int    64
  2312.                   pop    ebx
  2313.           End;
  2314. (* -------------------------------------------------------- *)
  2315. {62.10}   Function  WritePCIDword(Bus, Device, Func, Reg: Byte; Data: Dword): Dword; StdCall;
  2316.           Asm
  2317.                   push   ebx
  2318.                   mov    eax, 62
  2319.                   mov    bl, 10
  2320.                   mov    bh, Bus
  2321.                   mov    cl, Reg
  2322.                   mov    ch, Device
  2323.                   shl    ch, 3
  2324.                   or     ch, Func
  2325.                   mov    edx, Data
  2326.                   int    64
  2327.                   pop    ebx
  2328.           End;
  2329. (* -------------------------------------------------------- *)
  2330. {63.1}    Procedure BoardWriteByte(Data: Byte); StdCall;
  2331.           Asm
  2332.                   push   ebx
  2333.                   mov    eax, 63
  2334.                   mov    ebx, 1
  2335.                   mov    cl, Data
  2336.                   int    64
  2337.                   pop    ebx
  2338.           End;
  2339. (* -------------------------------------------------------- *)
  2340. {63.2}    Function  BoardReadByte(Var Data: Byte): Dword; StdCall;
  2341.           Asm
  2342.                   push   ebx
  2343.                   mov    eax, 63
  2344.                   mov    ebx, 2
  2345.                   int    64
  2346.                   mov    ecx, Data
  2347.                   mov    [ecx], al
  2348.                   mov    eax, ebx
  2349.                   pop    ebx
  2350.           End;
  2351. (* -------------------------------------------------------- *)
  2352. {64}      Function  ReallocAppMemory(Count: Dword): Integer; StdCall;
  2353.           Asm
  2354.                   push   ebx
  2355.                   mov    eax, 64
  2356.                   mov    ebx, 1
  2357.                   mov    ecx, Count
  2358.                   int    64
  2359.                   pop    ebx
  2360.           End;
  2361. (* -------------------------------------------------------- *)
  2362. {65}      Procedure DrawImageEx(Const Image; Left, Top: Integer; Width, Height: Dword; BPP: Dword; Const Palette: Pointer; Padding: Dword); StdCall;
  2363.           Asm
  2364.                   push   ebx
  2365.                   mov    eax, 65
  2366.                   mov    ebx, Image
  2367.                   mov    ecx, Width
  2368.                   mov    edx, Left
  2369.                   shl    ecx, 16
  2370.                   shl    edx, 16
  2371.                   or     ecx, Height
  2372.                   or     edx, Top
  2373.                   mov    esi, BPP
  2374.                   mov    edi, Palette
  2375.                   mov    ebp, Padding
  2376.                   int    64
  2377.                   pop    ebx
  2378.           End;
  2379. (* -------------------------------------------------------- *)
  2380. {66.1}    Procedure SetKeyboardInputMode(Mode: Dword); StdCall;
  2381.           Asm
  2382.                   push   ebx
  2383.                   mov    eax, 66
  2384.                   mov    ebx, 1
  2385.                   mov    ecx, Mode
  2386.                   int    64
  2387.                   pop    ebx
  2388.           End;
  2389. (* -------------------------------------------------------- *)
  2390. {66.2}    Function  GetKeyboardInputMode: Dword; StdCall;
  2391.           Asm
  2392.                   push   ebx
  2393.                   mov    eax, 66
  2394.                   mov    ebx, 2
  2395.                   int    64
  2396.                   pop    ebx
  2397.           End;
  2398. (* -------------------------------------------------------- *)
  2399. {66.3}    Function  GetControlKeyState: Dword; StdCall;
  2400.           Asm
  2401.                   push   ebx
  2402.                   mov    eax, 66
  2403.                   mov    ebx, 3
  2404.                   int    64
  2405.                   pop    ebx
  2406.           End;
  2407. (* -------------------------------------------------------- *)
  2408. {66.4}    Function  SetHotKey(ScanCode, Control: Dword): Integer; StdCall;
  2409.           Asm
  2410.                   push   ebx
  2411.                   mov    eax, 66
  2412.                   mov    ebx, 4
  2413.                   mov    ecx, ScanCode
  2414.                   mov    edx, Control
  2415.                   int    64
  2416.                   pop    ebx
  2417.           End;
  2418. (* -------------------------------------------------------- *)
  2419. {66.5}    Function  ResetHotKey(ScanCode, Control: Dword): Integer; StdCall;
  2420.           Asm
  2421.                   push   ebx
  2422.                   mov    eax, 66
  2423.                   mov    ebx, 4
  2424.                   mov    ecx, ScanCode
  2425.                   mov    edx, Control
  2426.                   int    64
  2427.                   pop    ebx
  2428.           End;
  2429. (* -------------------------------------------------------- *)
  2430. {66.6}    Procedure KeyboardLock; StdCall;
  2431.           Asm
  2432.                   push   ebx
  2433.                   mov    eax, 66
  2434.                   mov    ebx, 6
  2435.                   int    64
  2436.                   pop    ebx
  2437.           End;
  2438. (* -------------------------------------------------------- *)
  2439. {66.7}    Procedure KeyboardUnlock; StdCall;
  2440.           Asm
  2441.                   push   ebx
  2442.                   mov    eax, 66
  2443.                   mov    ebx, 7
  2444.                   int    64
  2445.                   pop    ebx
  2446.           End;
  2447. (* -------------------------------------------------------- *)
  2448. {67}      Procedure SetWindowPos(Left, Top, Right, Bottom: Integer); StdCall;
  2449.           Asm
  2450.                   push   ebx
  2451.                   push   esi
  2452.                   mov    eax, 67
  2453.                   mov    ebx, Left
  2454.                   mov    ecx, Top
  2455.                   mov    edx, Right
  2456.                   mov    esi, Bottom
  2457.                   int    64
  2458.                   pop    esi
  2459.                   pop    ebx
  2460.           End;
  2461. (* -------------------------------------------------------- *)
  2462. {68.0}    Function  GetTaskSwitchCount: Dword; StdCall;
  2463.           Asm
  2464.                   push   ebx
  2465.                   mov    eax, 68
  2466.                   mov    ebx, 0
  2467.                   int    64
  2468.                   pop    ebx
  2469.           End;
  2470. (* -------------------------------------------------------- *)
  2471. {68.1}    Procedure SwitchThread; StdCall;
  2472.           Asm
  2473.                   push   ebx
  2474.                   mov    eax, 68
  2475.                   mov    ebx, 1
  2476.                   int    64
  2477.                   pop    ebx
  2478.           End;
  2479. (* -------------------------------------------------------- *)
  2480. {68.2.0}  Function  EnableRDPMC: Dword; StdCall;
  2481.           Asm
  2482.                   push   ebx
  2483.                   mov    eax, 68
  2484.                   mov    ebx, 2
  2485.                   mov    ecx, 0
  2486.                   int    64
  2487.                   pop    ebx
  2488.           End;
  2489. (* -------------------------------------------------------- *)
  2490. {68.2.1}  Function  IsCacheEnabled: Dword; StdCall;
  2491.           Asm
  2492.                   push   ebx
  2493.                   mov    eax, 68
  2494.                   mov    ebx, 2
  2495.                   mov    ecx, 1
  2496.                   int    64
  2497.                   pop    ebx
  2498.           End;
  2499. (* -------------------------------------------------------- *)
  2500. {68.2.2}  Procedure EnableCache; StdCall;
  2501.           Asm
  2502.                   push   ebx
  2503.                   mov    eax, 68
  2504.                   mov    ebx, 2
  2505.                   mov    ecx, 2
  2506.                   int    64
  2507.                   pop    ebx
  2508.           End;
  2509. (* -------------------------------------------------------- *)
  2510. {68.2.3}  Procedure DisableCache; StdCall;
  2511.           Asm
  2512.                   push   ebx
  2513.                   mov    eax, 68
  2514.                   mov    ebx, 2
  2515.                   mov    ecx, 3
  2516.                   int    64
  2517.                   pop    ebx
  2518.           End;
  2519. (* -------------------------------------------------------- *)
  2520. {68.3}    {ReadMSR}
  2521. (* -------------------------------------------------------- *)
  2522. {68.4}    {WriteMSR}
  2523. (* -------------------------------------------------------- *)
  2524. {68.5}    {UNDEFINED}
  2525. (* -------------------------------------------------------- *)
  2526. {68.6}    {UNDEFINED}
  2527. (* -------------------------------------------------------- *)
  2528. {68.7}    {UNDEFINED}
  2529. (* -------------------------------------------------------- *)
  2530. {68.8}    {UNDEFINED}
  2531. (* -------------------------------------------------------- *)
  2532. {68.9}    {UNDEFINED}
  2533. (* -------------------------------------------------------- *)
  2534. {68.10}   {UNDEFINED}
  2535. (* -------------------------------------------------------- *)
  2536. {68.11}   Function  HeapCreate: Dword; StdCall;
  2537.           Asm
  2538.                   push   ebx
  2539.                   mov    eax, 68
  2540.                   mov    ebx, 11
  2541.                   int    64
  2542.                   pop    ebx
  2543.           End;
  2544. (* -------------------------------------------------------- *)
  2545. {68.12}   Function  HeapAllocate(Bytes: Dword): Pointer; StdCall;
  2546.           Asm
  2547.                   push   ebx
  2548.                   mov    eax, 68
  2549.                   mov    ebx, 12
  2550.                   mov    ecx, Bytes
  2551.                   int    64
  2552.                   pop    ebx
  2553.           End;
  2554. (* -------------------------------------------------------- *)
  2555. {68.13}   Function  HeapFree(MemPtr: Pointer): Dword; StdCall;
  2556.           Asm
  2557.                   push   ebx
  2558.                   mov    eax, 68
  2559.                   mov    ebx, 13
  2560.                   mov    ecx, MemPtr
  2561.                   int    64
  2562.                   pop    ebx
  2563.           End;
  2564. (* -------------------------------------------------------- *)
  2565. {68.14}   Procedure WaitSignal(Var Buffer: TSignalBuffer); StdCall;
  2566.           Asm
  2567.                   push   ebx
  2568.                   mov    eax, 68
  2569.                   mov    ebx, 14
  2570.                   mov    ecx, Buffer
  2571.                   int    64
  2572.                   pop    ebx
  2573.           End;
  2574. (* -------------------------------------------------------- *)
  2575. {68.15}   {UNDEFINED}
  2576. (* -------------------------------------------------------- *)
  2577. {68.16}   Function  GetDriver(Name: PChar): Dword; StdCall;
  2578.           Asm
  2579.                   push   ebx
  2580.                   mov    eax, 68
  2581.                   mov    ebx, 16
  2582.                   mov    ecx, Name
  2583.                   int    64
  2584.                   pop    ebx
  2585.           End;
  2586. (* -------------------------------------------------------- *)
  2587. {68.17}   Function  ControlDriver(Var CtrlStructure: TCtrlDriver): Dword; StdCall;
  2588.           Asm
  2589.                   push   ebx
  2590.                   mov    eax, 68
  2591.                   mov    ebx, 17
  2592.                   mov    ecx, CtrlStructure
  2593.                   int    64
  2594.                   pop    ebx
  2595.           End;
  2596. (* -------------------------------------------------------- *)
  2597. {68.18}   {UNDEFINED}
  2598. (* -------------------------------------------------------- *)
  2599. {68.19}   Function  LoadLibrary(Path: PChar): Pointer; StdCall;
  2600.           Asm
  2601.                   push   ebx
  2602.                   mov    eax, 68
  2603.                   mov    ebx, 19
  2604.                   mov    ecx, Path
  2605.                   int    64
  2606.                   pop    ebx
  2607.           End;
  2608. (* -------------------------------------------------------- *)
  2609. {68.20}   Function  HeapReallocate(MemPtr: Pointer; Bytes: Dword): Pointer; StdCall;
  2610.           Asm
  2611.                   push   ebx
  2612.                   mov    eax, 68
  2613.                   mov    ebx, 20
  2614.                   mov    ecx, Bytes
  2615.                   mov    edx, MemPtr
  2616.                   int    64
  2617.                   pop    ebx
  2618.           End;
  2619. (* -------------------------------------------------------- *)
  2620. {68.21}   Function  LoadDriver(Name, CmdLine: PChar): Dword; StdCall;
  2621.           Asm
  2622.                   push   ebx
  2623.                   mov    eax, 68
  2624.                   mov    ebx, 21
  2625.                   mov    ecx, Name
  2626.                   mov    edx, CmdLine
  2627.                   int    64
  2628.                   pop    ebx
  2629.           End;
  2630. (* -------------------------------------------------------- *)
  2631. {68.22}   Function  SharedMemoryOpen(Name: PChar; Bytes: Dword; Flags: Dword): Pointer; StdCall;
  2632.           Asm
  2633.                   push   ebx
  2634.                   push   esi
  2635.                   mov    eax, 68
  2636.                   mov    ebx, 22
  2637.                   mov    ecx, Name
  2638.                   mov    edx, Bytes
  2639.                   mov    esi, Flags
  2640.                   int    64
  2641.                   pop    esi
  2642.                   pop    ebx
  2643.           End;
  2644. (* -------------------------------------------------------- *)
  2645. {68.23}   Function  SharedMemoryClose(Name: PChar): Dword; StdCall;
  2646.           Asm
  2647.                   push   ebx
  2648.                   mov    eax, 68
  2649.                   mov    ebx, 23
  2650.                   mov    ecx, Name
  2651.                   int    64
  2652.                   pop    ebx
  2653.           End;
  2654. (* -------------------------------------------------------- *)
  2655. {68.24}   Function  SetExceptionHandler(Handler: Pointer; Mask: Dword; Var OldMask: Dword): Pointer; StdCall;
  2656.           Asm
  2657.                   push   ebx
  2658.                   mov    eax, 68
  2659.                   mov    ebx, 24
  2660.                   mov    ecx, Handler
  2661.                   mov    edx, Mask
  2662.                   int    64
  2663.                   mov    ecx, OldMask
  2664.                   mov    [ecx], ebx
  2665.                   pop    ebx
  2666.           End;
  2667. (* -------------------------------------------------------- *)
  2668. {68.25}   Function  SetExceptionActivity(Signal, Activity: Dword): Integer; StdCall;
  2669.           Asm
  2670.                   push   ebx
  2671.                   mov    eax, 68
  2672.                   mov    ebx, 25
  2673.                   mov    ecx, Signal
  2674.                   mov    edx, Activity
  2675.                   int    64
  2676.                   pop    ebx
  2677.           End;
  2678. (* -------------------------------------------------------- *)
  2679. {68.26}   Procedure ReleaseMemoryPages(MemPtr: Pointer; Offset, Size: Dword); StdCall;
  2680.           Asm
  2681.                   push   ebx
  2682.                   push   esi
  2683.                   mov    eax, 68
  2684.                   mov    ebx, 26
  2685.                   mov    ecx, MemPtr
  2686.                   mov    edx, &Offset
  2687.                   mov    esi, Size
  2688.                   int    64
  2689.                   pop    esi
  2690.                   pop    ebx
  2691.           End;
  2692. (* -------------------------------------------------------- *)
  2693. {68.27}   Function  LoadFile(Path: PChar; Var Size: Dword): Pointer; StdCall;
  2694.           Asm
  2695.                   push   ebx
  2696.                   mov    eax, 68
  2697.                   mov    ebx, 27
  2698.                   mov    ecx, Path
  2699.                   int    64
  2700.                   mov    ecx, Size
  2701.                   mov    [ecx], edx
  2702.                   pop    ebx
  2703.           End;
  2704. (* -------------------------------------------------------- *)
  2705. {69.0}    Procedure SetDebugBuffer(Const Buffer: TDebugBuffer); StdCall;
  2706.           Asm
  2707.                   push   ebx
  2708.                   mov    eax, 69
  2709.                   mov    ebx, 0
  2710.                   mov    ecx, Buffer
  2711.                   int    64
  2712.                   pop    ebx
  2713.           End;
  2714. (* -------------------------------------------------------- *)
  2715. {69.1}    Procedure GetThreadContext(ID: Dword; Var Context: TThreadContext); StdCall;
  2716.           Const SIZEOF_TTHREADCONTEXT = SizeOf(TThreadContext);
  2717.           Asm
  2718.                   push   ebx
  2719.                   push   esi
  2720.                   mov    eax, 69
  2721.                   mov    ebx, 1
  2722.                   mov    ecx, ID
  2723.                   mov    edx, SIZEOF_TTHREADCONTEXT
  2724.                   mov    esi, Context
  2725.                   int    64
  2726.                   pop    esi
  2727.                   pop    ebx
  2728.           End;
  2729. (* -------------------------------------------------------- *)
  2730. {69.2}    Procedure SetThreadContext(ID: Dword; Const Context: TThreadContext); StdCall;
  2731.           Const SIZEOF_TTHREADCONTEXT = SizeOf(TThreadContext);
  2732.           Asm
  2733.                   push   ebx
  2734.                   push   esi
  2735.                   mov    eax, 69
  2736.                   mov    ebx, 2
  2737.                   mov    ecx, ID
  2738.                   mov    edx, SIZEOF_TTHREADCONTEXT
  2739.                   mov    esi, Context
  2740.                   int    64
  2741.                   pop    esi
  2742.                   pop    ebx
  2743.           End;
  2744. (* -------------------------------------------------------- *)
  2745. {69.3}    Procedure DetachThread(ID: Dword); StdCall;
  2746.           Asm
  2747.                   push   ebx
  2748.                   mov    eax, 69
  2749.                   mov    ebx, 3
  2750.                   mov    ecx, ID
  2751.                   int    64
  2752.                   pop    ebx
  2753.           End;
  2754. (* -------------------------------------------------------- *)
  2755. {69.4}    Procedure SuspendThread(ID: Dword); StdCall;
  2756.           Asm
  2757.                   push   ebx
  2758.                   mov    eax, 69
  2759.                   mov    ebx, 4
  2760.                   mov    ecx, ID
  2761.                   int    64
  2762.                   pop    ebx
  2763.           End;
  2764. (* -------------------------------------------------------- *)
  2765. {69.5}    Procedure ResumeThread(ID: Dword); StdCall;
  2766.           Asm
  2767.                   push   ebx
  2768.                   mov    eax, 69
  2769.                   mov    ebx, 5
  2770.                   mov    ecx, ID
  2771.                   int    64
  2772.                   pop    ebx
  2773.           End;
  2774. (* -------------------------------------------------------- *)
  2775. {69.6}    Function  ReadProcessMemory(ID, Count: Dword; Const Src; Var Dst): Integer; StdCall;
  2776.           Asm
  2777.                   push   ebx
  2778.                   push   esi
  2779.                   push   edi
  2780.                   mov    eax, 69
  2781.                   mov    ebx, 6
  2782.                   mov    ecx, ID
  2783.                   mov    edx, Count
  2784.                   mov    esi, Src
  2785.                   mov    edi, Dst
  2786.                   int    64
  2787.                   pop    edi
  2788.                   pop    esi
  2789.                   pop    ebx
  2790.           End;
  2791. (* -------------------------------------------------------- *)
  2792. {69.7}    Function  WriteProcessMemory(ID, Count: Dword; Const Src; Var Dst): Integer; StdCall;
  2793.           Asm
  2794.                   push   ebx
  2795.                   push   esi
  2796.                   push   edi
  2797.                   mov    eax, 69
  2798.                   mov    ebx, 7
  2799.                   mov    ecx, ID
  2800.                   mov    edx, Count
  2801.                   mov    esi, Dst
  2802.                   mov    edi, Src
  2803.                   int    64
  2804.                   pop    edi
  2805.                   pop    esi
  2806.                   pop    ebx
  2807.           End;
  2808. (* -------------------------------------------------------- *)
  2809. {69.8}    Procedure DebugTerminate(ID: Dword); StdCall;
  2810.           Asm
  2811.                   push   ebx
  2812.                   mov    eax, 69
  2813.                   mov    ebx, 8
  2814.                   mov    ecx, ID
  2815.                   int    64
  2816.                   pop    ebx
  2817.           End;
  2818. (* -------------------------------------------------------- *)
  2819. {69.9}    Function  SetBreakPoint(ID: Dword; Index, Flags: Byte; Address: Pointer): Integer; StdCall;
  2820.           Asm
  2821.                   push   ebx
  2822.                   push   esi
  2823.                   mov    eax, 69
  2824.                   mov    ebx, 9
  2825.                   mov    ecx, ID
  2826.                   mov    dl, Index
  2827.                   mov    dh, Flags
  2828.                   mov    esi, Address
  2829.                   int    64
  2830.                   pop    esi
  2831.                   pop    ebx
  2832.           End;
  2833. (* -------------------------------------------------------- *)
  2834. {69.9}    Function  ResetBreakPoint(ID: Dword; Index, Flags: Byte; Address: Pointer): Integer; StdCall;
  2835.           Asm
  2836.                   push   ebx
  2837.                   push   esi
  2838.                   mov    eax, 69
  2839.                   mov    ebx, 9
  2840.                   mov    ecx, ID
  2841.                   mov    dl, Index
  2842.                   mov    dh, Flags
  2843.                   or     dh, $80
  2844.                   mov    esi, Address
  2845.                   int    64
  2846.                   pop    esi
  2847.                   pop    ebx
  2848.           End;
  2849. (* -------------------------------------------------------- *)
  2850. {70.0}    Function  ReadFile(Path: PChar; Var Buffer; Count, LoPos, HiPos: Cardinal; Var BytesRead: Dword): Integer; StdCall;
  2851.           Asm
  2852.                   push   ebx
  2853.                   push   Path
  2854.                   dec    esp
  2855.                   mov    byte[esp], 0
  2856.                   push   Buffer
  2857.                   push   Count
  2858.                   push   HiPos
  2859.                   push   LoPos
  2860.                   push   0
  2861.                   mov    ebx, esp
  2862.                   mov    eax, 70
  2863.                   int    64
  2864.                   add    esp, 25
  2865.                   mov    ecx, BytesRead
  2866.                   mov    [ecx], ebx
  2867.                   pop    ebx
  2868.           End;
  2869. (* -------------------------------------------------------- *)
  2870. {70.1}    Function  ReadFolder(Path: PChar; Var Buffer; Count, Start, Flags: Cardinal; Var BlocksRead: Dword): Integer; StdCall;
  2871.           Asm
  2872.                   push   ebx
  2873.                   push   Path
  2874.                   dec    esp
  2875.                   mov    byte[esp], 0
  2876.                   push   Buffer
  2877.                   push   Count
  2878.                   push   Flags
  2879.                   push   Start
  2880.                   push   1
  2881.                   mov    ebx, esp
  2882.                   mov    eax, 70
  2883.                   int    64
  2884.                   add    esp, 25
  2885.                   mov    ecx, BlocksRead
  2886.                   mov    [ecx], ebx                  
  2887.                   pop    ebx
  2888.           End;
  2889. (* -------------------------------------------------------- *)
  2890. {70.2}    Function  CreateFile(Path: PChar): Integer; StdCall;
  2891.           Asm
  2892.                   push   ebx
  2893.                   push   Path
  2894.                   dec    esp
  2895.                   mov    byte[esp], 0
  2896.                   push   0
  2897.                   push   0
  2898.                   push   0
  2899.                   push   0
  2900.                   push   2
  2901.                   mov    ebx, esp
  2902.                   mov    eax, 70
  2903.                   int    64
  2904.                   add    esp, 25
  2905.                   pop    ebx
  2906.           End;
  2907. (* -------------------------------------------------------- *)
  2908. {70.3}    Function  WriteFile(Path: PChar; Const Buffer; Count, LoPos, HiPos: Cardinal; Var BytesWritten: Dword): Integer; StdCall;
  2909.           Asm
  2910.                   push   ebx
  2911.                   push   Path
  2912.                   dec    esp
  2913.                   mov    byte[esp], 0
  2914.                   push   Buffer
  2915.                   push   Count
  2916.                   push   HiPos
  2917.                   push   LoPos
  2918.                   push   3
  2919.                   mov    ebx, esp
  2920.                   mov    eax, 70
  2921.                   int    64
  2922.                   add    esp, 25
  2923.                   mov    ecx, BytesWritten
  2924.                   mov    [ecx], ebx                    
  2925.                   pop    ebx
  2926.           End;
  2927. (* -------------------------------------------------------- *)
  2928. {70.4}    Function  ResizeFile(Path: PChar; LoSize, HiSize: Cardinal): Integer; StdCall;
  2929.           Asm
  2930.                   push   ebx
  2931.                   push   Path
  2932.                   dec    esp
  2933.                   mov    byte[esp], 0
  2934.                   push   0
  2935.                   push   0
  2936.                   push   HiSize
  2937.                   push   LoSize
  2938.                   push   4
  2939.                   mov    ebx, esp
  2940.                   mov    eax, 70
  2941.                   int    64
  2942.                   add    esp, 25
  2943.                   pop    ebx
  2944.           End;
  2945. (* -------------------------------------------------------- *)
  2946. {70.5}    Function  GetFileAttributes(Path: PChar; Var Buffer: TFileAttributes): Integer; StdCall;
  2947.           Asm
  2948.                   push   ebx
  2949.                   push   Path
  2950.                   dec    esp
  2951.                   mov    byte[esp], 0
  2952.                   push   Buffer
  2953.                   push   0
  2954.                   push   0
  2955.                   push   0
  2956.                   push   5
  2957.                   mov    ebx, esp
  2958.                   mov    eax, 70
  2959.                   int    64
  2960.                   add    esp, 25
  2961.                   pop    ebx
  2962.           End;
  2963. (* -------------------------------------------------------- *)
  2964. {70.6}    Function  SetFileAttributes(Path: PChar; Var Buffer: TFileAttributes): Integer; StdCall;
  2965.           Asm
  2966.                   push   ebx
  2967.                   push   Path
  2968.                   dec    esp
  2969.                   mov    byte[esp], 0
  2970.                   push   Buffer
  2971.                   push   0
  2972.                   push   0
  2973.                   push   0
  2974.                   push   6
  2975.                   mov    ebx, esp
  2976.                   mov    eax, 70
  2977.                   int    64
  2978.                   add    esp, 25
  2979.                   pop    ebx
  2980.           End;
  2981. (* -------------------------------------------------------- *)
  2982. {70.7}    Function  RunFile(Path, CmdLine: PChar): Integer; StdCall;
  2983.           Asm
  2984.                   push   ebx
  2985.                   push   Path
  2986.                   dec    esp
  2987.                   mov    byte[esp], 0
  2988.                   push   0
  2989.                   push   0
  2990.                   push   CmdLine
  2991.                   push   0
  2992.                   push   7
  2993.                   mov    ebx, esp
  2994.                   mov    eax, 70
  2995.                   int    64
  2996.                   add    esp, 25
  2997.                   pop    ebx
  2998.           End;
  2999. (* -------------------------------------------------------- *)
  3000. {70.7}    Function  DebugFile(Path, CmdLine: PChar): Integer; StdCall;
  3001.           Asm
  3002.                   push   ebx
  3003.                   push   Path
  3004.                   dec    esp
  3005.                   mov    byte[esp], 0
  3006.                   push   0
  3007.                   push   0
  3008.                   push   CmdLine
  3009.                   push   1
  3010.                   push   7
  3011.                   mov    ebx, esp
  3012.                   mov    eax, 70
  3013.                   int    64
  3014.                   add    esp, 25
  3015.                   pop    ebx
  3016.           End;
  3017. (* -------------------------------------------------------- *)
  3018. {70.8}    Function  DeleteFile(Path: PChar): Integer; StdCall;
  3019.           Asm
  3020.                   push   ebx
  3021.                   push   Path
  3022.                   dec    esp
  3023.                   mov    byte[esp], 0
  3024.                   push   0
  3025.                   push   0
  3026.                   push   0
  3027.                   push   0
  3028.                   push   8
  3029.                   mov    ebx, esp
  3030.                   mov    eax, 70
  3031.                   int    64
  3032.                   add    esp, 25
  3033.                   pop    ebx
  3034.           End;
  3035. (* -------------------------------------------------------- *)
  3036. {70.9}    Function  CreateFolder(Path: PChar): Integer; StdCall;
  3037.           Asm
  3038.                   push   ebx
  3039.                   push   Path
  3040.                   dec    esp
  3041.                   mov    byte[esp], 0
  3042.                   push   0
  3043.                   push   0
  3044.                   push   0
  3045.                   push   0
  3046.                   push   9
  3047.                   mov    ebx, esp
  3048.                   mov    eax, 70
  3049.                   int    64
  3050.                   add    esp, 25
  3051.                   pop    ebx
  3052.           End;
  3053. (* -------------------------------------------------------- *)
  3054. {71.1}    Procedure SetWindowCaption(Caption: PChar); StdCall;
  3055.           Asm
  3056.                   push   ebx
  3057.                   mov    eax, 71
  3058.                   mov    ebx, 1
  3059.                   mov    ecx, Caption
  3060.                   int    64
  3061.                   pop    ebx
  3062.           End;
  3063. (* -------------------------------------------------------- *)
  3064. {72.1.2}  Function  SendActiveWindowKey(KeyCode: Dword): Integer; StdCall;
  3065.           Asm
  3066.                   push   ebx
  3067.                   mov    eax, 72
  3068.                   mov    ebx, 1
  3069.                   mov    ecx, 2
  3070.                   mov    edx, KeyCode
  3071.                   int    64
  3072.                   pop    ebx
  3073.           End;
  3074. (* -------------------------------------------------------- *)
  3075. {72.1.3}  Function  SendActiveWindowButton(ButtonID: Dword): Integer; StdCall;
  3076.           Asm
  3077.                   push   ebx
  3078.                   mov    eax, 72
  3079.                   mov    ebx, 1
  3080.                   mov    ecx, 3
  3081.                   mov    edx, ButtonID
  3082.                   int    64
  3083.                   pop    ebx
  3084.           End;
  3085. (* -------------------------------------------------------- *)
  3086. {73}      Procedure Blit(Const Src; SrcX, SrcY: Integer; SrcW, SrcH: Dword; DstX, DstY: Integer; DstW, DstH: Dword; Stride, Flags: Dword); StdCall;
  3087.           Asm
  3088.                   push   Stride
  3089.                   push   Src
  3090.                   push   SrcH
  3091.                   push   SrcW
  3092.                   push   SrcY
  3093.                   push   SrcX
  3094.                   push   DstH
  3095.                   push   DstW
  3096.                   push   DstY
  3097.                   push   DstX
  3098.                   mov    eax, 73
  3099.                   mov    ebx, Flags
  3100.                   mov    ecx, esp
  3101.                   int    64
  3102.                   add    esp, 40
  3103.           End;
  3104. (* -------------------------------------------------------- *)
  3105. {74.-1}   Function  GetActiveNetworkDevices: Dword; StdCall;
  3106.           Asm
  3107.                   push   ebx
  3108.                   mov    eax, 74
  3109.                   mov    bl, -1
  3110.                   int    64
  3111.                   pop    ebx
  3112.           End;
  3113. (* -------------------------------------------------------- *)
  3114. {74.0}    Function  GetNetworkDeviceType(Device: Byte): Integer; StdCall;
  3115.           Asm
  3116.                   push   ebx
  3117.                   mov    eax, 74
  3118.                   mov    bl, 0
  3119.                   mov    bh, Device
  3120.                   int    64
  3121.                   pop    ebx
  3122.           End;
  3123. (* -------------------------------------------------------- *)
  3124. {74.1}    Function  GetNetworkDeviceName(Device: Byte; Var Buffer): Integer; StdCall;
  3125.           Asm
  3126.                   push   ebx
  3127.                   mov    eax, 74
  3128.                   mov    bl, 1
  3129.                   mov    bh, Device
  3130.                   mov    ecx, Buffer
  3131.                   int    64
  3132.                   pop    ebx
  3133.           End;
  3134. (* -------------------------------------------------------- *)
  3135. {74.2}    Function  ResetNetworkDevice(Device: Byte): Integer; StdCall;
  3136.           Asm
  3137.                   push   ebx
  3138.                   mov    eax, 74
  3139.                   mov    bl, 2
  3140.                   mov    bh, Device
  3141.                   int    64
  3142.                   pop    ebx
  3143.           End;
  3144. (* -------------------------------------------------------- *)
  3145. {74.3}    Function  StopNetworkDevice(Device: Byte): Integer; StdCall;
  3146.           Asm
  3147.                   push   ebx
  3148.                   mov    eax, 74
  3149.                   mov    bl, 3
  3150.                   mov    bh, Device
  3151.                   int    64
  3152.                   pop    ebx
  3153.           End;
  3154. (* -------------------------------------------------------- *)
  3155. {74.4}    Function  GetNetworkDevicePointer(Device: Byte): Pointer; StdCall;
  3156.           Asm
  3157.                   push   ebx
  3158.                   mov    eax, 74
  3159.                   mov    bl, 4
  3160.                   mov    bh, Device
  3161.                   int    64
  3162.                   pop    ebx
  3163.           End;
  3164. (* -------------------------------------------------------- *)
  3165. {74.5}    {UNDEFINED}
  3166. (* -------------------------------------------------------- *)
  3167. {74.6}    Function  GetSentPackets(Device: Byte): Integer; StdCall;
  3168.           Asm
  3169.                   push   ebx
  3170.                   mov    eax, 74
  3171.                   mov    bl, 6
  3172.                   mov    bh, Device
  3173.                   int    64
  3174.                   pop    ebx
  3175.           End;
  3176. (* -------------------------------------------------------- *)
  3177. {74.7}    Function  GetReceivedPackets(Device: Byte): Integer; StdCall;
  3178.           Asm
  3179.                   push   ebx
  3180.                   mov    eax, 74
  3181.                   mov    bl, 7
  3182.                   mov    bh, Device
  3183.                   int    64
  3184.                   pop    ebx
  3185.           End;
  3186. (* -------------------------------------------------------- *)
  3187. {74.8}    Function  GetSentBytes(Device: Byte): Integer; StdCall;
  3188.           Asm
  3189.                   push   ebx
  3190.                   mov    eax, 74
  3191.                   mov    bl, 8
  3192.                   mov    bh, Device
  3193.                   int    64
  3194.                   pop    ebx
  3195.           End;
  3196. (* -------------------------------------------------------- *)
  3197. {74.9}    Function  GetReceivedBytes(Device: Byte): Integer; StdCall;
  3198.           Asm
  3199.                   push   ebx
  3200.                   mov    eax, 74
  3201.                   mov    bl, 9
  3202.                   mov    bh, Device
  3203.                   int    64
  3204.                   pop    ebx
  3205.           End;
  3206. (* -------------------------------------------------------- *)
  3207. {74.10}   Function  GetLinkStatus(Device: Byte): Integer; StdCall;
  3208.           Asm
  3209.                   push   ebx
  3210.                   mov    eax, 74
  3211.                   mov    bl, 10
  3212.                   mov    bh, Device
  3213.                   int    64
  3214.                   pop    ebx
  3215.           End;
  3216. (* -------------------------------------------------------- *)
  3217. {75.0}    Function  OpenSocket(Domain, Kind, Protocol: Dword): Dword; StdCall;
  3218.           Asm
  3219.                   push   ebx
  3220.                   push   esi
  3221.                   mov    eax, 75
  3222.                   mov    bl, 0
  3223.                   mov    ecx, Domain
  3224.                   mov    edx, Kind
  3225.                   mov    esi, Protocol
  3226.                   int    64
  3227.                   pop    esi
  3228.                   pop    ebx
  3229.           End;
  3230. (* -------------------------------------------------------- *)
  3231. {75.1}    Function  CloseSocket(Socket: Dword): Integer; StdCall;
  3232.           Asm
  3233.                   push   ebx
  3234.                   mov    eax, 75
  3235.                   mov    bl, 1
  3236.                   mov    ecx, Socket
  3237.                   int    64
  3238.                   pop    ebx
  3239.           End;
  3240. (* -------------------------------------------------------- *)
  3241. {75.2}    Function  SocketBind(Socket: Dword; Var SockAddr: TSockAddr): Integer; StdCall;
  3242.           Const SIZEOF_TSOCKADDR = SizeOf(TSockAddr);
  3243.           Asm
  3244.                   push   ebx
  3245.                   push   esi
  3246.                   mov    eax, 75
  3247.                   mov    bl, 2
  3248.                   mov    ecx, Socket
  3249.                   mov    edx, SockAddr
  3250.                   mov    esi, SIZEOF_TSOCKADDR
  3251.                   int    64
  3252.                   pop    esi
  3253.                   pop    ebx
  3254.           End;
  3255. (* -------------------------------------------------------- *)
  3256. {75.3}    Function  SocketListen(Socket: Dword; Var BackLog): Integer; StdCall;
  3257.           Asm
  3258.                   push   ebx
  3259.                   mov    eax, 75
  3260.                   mov    bl, 3
  3261.                   mov    ecx, Socket
  3262.                   mov    edx, BackLog
  3263.                   int    64
  3264.                   pop    ebx
  3265.           End;
  3266. (* -------------------------------------------------------- *)
  3267. {75.4}    Function  SocketConnect(Socket: Dword; Var SockAddr: TSockAddr): Integer; StdCall;
  3268.           Const SIZEOF_TSOCKADDR = SizeOf(TSockAddr);
  3269.           Asm
  3270.                   push   ebx
  3271.                   push   esi
  3272.                   mov    eax, 75
  3273.                   mov    bl, 4
  3274.                   mov    ecx, Socket
  3275.                   mov    edx, SockAddr
  3276.                   mov    esi, SIZEOF_TSOCKADDR
  3277.                   int    64
  3278.                   pop    esi
  3279.                   pop    ebx
  3280.           End;
  3281. (* -------------------------------------------------------- *)
  3282. {75.5}    Function  SocketAccept(Socket: Dword; Var SockAddr: TSockAddr): Dword; StdCall;
  3283.           Const SIZEOF_TSOCKADDR = SizeOf(TSockAddr);
  3284.           Asm
  3285.                   push   ebx
  3286.                   push   esi
  3287.                   mov    eax, 75
  3288.                   mov    bl, 5
  3289.                   mov    ecx, Socket
  3290.                   mov    edx, SockAddr
  3291.                   mov    esi, SIZEOF_TSOCKADDR
  3292.                   int    64
  3293.                   pop    esi
  3294.                   pop    ebx
  3295.           End;
  3296. (* -------------------------------------------------------- *)
  3297. {75.6}    Function  SocketSend(Socket: Dword; Const Buffer; Size, Flags: Dword): Integer; StdCall;
  3298.           Asm
  3299.                   push   ebx
  3300.                   push   esi
  3301.                   push   edi
  3302.                   mov    eax, 75
  3303.                   mov    bl, 6
  3304.                   mov    ecx, Socket
  3305.                   mov    edx, Buffer
  3306.                   mov    esi, Size
  3307.                   mov    edi, Flags
  3308.                   int    64
  3309.                   pop    edi
  3310.                   pop    esi
  3311.                   pop    ebx
  3312.           End;
  3313. (* -------------------------------------------------------- *)
  3314. {75.7}    Function  SocketReceive(Socket: Dword; Var Buffer; Size, Flags: Dword): Integer; StdCall;
  3315.           Asm
  3316.                   push   ebx
  3317.                   push   esi
  3318.                   push   edi
  3319.                   mov    eax, 75
  3320.                   mov    bl, 7
  3321.                   mov    ecx, Socket
  3322.                   mov    edx, Buffer
  3323.                   mov    esi, Size
  3324.                   mov    edi, Flags
  3325.                   int    64
  3326.                   pop    edi
  3327.                   pop    esi
  3328.                   pop    ebx
  3329.           End;
  3330. (* -------------------------------------------------------- *)
  3331. {75.8}    Function  SetSocketOptions(Socket: Dword; Var OptStruct: TOptStruct): Integer; StdCall;
  3332.           Asm
  3333.                   push   ebx
  3334.                   mov    eax, 75
  3335.                   mov    bl, 8
  3336.                   mov    ecx, Socket
  3337.                   mov    edx, OptStruct
  3338.                   int    64
  3339.                   pop    ebx
  3340.           End;
  3341. (* -------------------------------------------------------- *)
  3342. {75.9}    Function  GetSocketOptions(Socket: Dword; Var OptStruct: TOptStruct): Integer; StdCall;
  3343.           Asm
  3344.                   push   ebx
  3345.                   mov    eax, 75
  3346.                   mov    bl, 9
  3347.                   mov    ecx, Socket
  3348.                   mov    edx, OptStruct
  3349.                   int    64
  3350.                   pop    ebx
  3351.           End;
  3352. (* -------------------------------------------------------- *)
  3353. {75.10}   Function  GetSocketPair(Var Socket1, Socket2: Dword): Integer; StdCall;
  3354.           Asm
  3355.                   push   ebx
  3356.                   mov    eax, 75
  3357.                   mov    bl, 10
  3358.                   int    64
  3359.                   mov    ecx, Socket1
  3360.                   mov    edx, Socket2
  3361.                   mov    [ecx], eax
  3362.                   mov    [edx], ebx
  3363.                   pop    ebx
  3364.           End;
  3365. (* -------------------------------------------------------- *)
  3366. {76.0.0}  Function  GetMAC(Device: Byte): Dword; StdCall;
  3367.           Asm
  3368.                   push   ebx
  3369.                   mov    eax, 76
  3370.                   mov    ebx, $00000000
  3371.                   mov    bl, 0
  3372.                   mov    bh, Device
  3373.                   int    64
  3374.                   pop    ebx
  3375.           End;
  3376. (* -------------------------------------------------------- *)
  3377. {76.1.0}  Function  GetIPv4SentPackets(Device: Byte): Dword; StdCall;
  3378.           Asm
  3379.                   push   ebx
  3380.                   mov    eax, 76
  3381.                   mov    ebx, $00010000
  3382.                   mov    bl, 0
  3383.                   mov    bh, Device
  3384.                   int    64
  3385.                   pop    ebx
  3386.           End;
  3387. (* -------------------------------------------------------- *)
  3388. {76.1.1}  Function  GetIPv4ReceivedPackets(Device: Byte): Dword; StdCall;
  3389.           Asm
  3390.                   push   ebx
  3391.                   mov    eax, 76
  3392.                   mov    ebx, $00010000
  3393.                   mov    bl, 1
  3394.                   mov    bh, Device
  3395.                   int    64
  3396.                   pop    ebx
  3397.           End;
  3398. (* -------------------------------------------------------- *)
  3399. {76.1.2}  Function  GetIPv4IP(Device: Byte): Dword; StdCall;
  3400.           Asm
  3401.                   push   ebx
  3402.                   mov    eax, 76
  3403.                   mov    ebx, $00010000
  3404.                   mov    bl, 2
  3405.                   mov    bh, Device
  3406.                   int    64
  3407.                   pop    ebx
  3408.           End;
  3409. (* -------------------------------------------------------- *)
  3410. {76.1.3}  Function  SetIPv4IP(Device: Byte; IP: Dword): Dword; StdCall;
  3411.           Asm
  3412.                   push   ebx
  3413.                   mov    eax, 76
  3414.                   mov    ebx, $00010000
  3415.                   mov    bl, 3
  3416.                   mov    bh, Device
  3417.                   mov    ecx, IP
  3418.                   int    64
  3419.                   pop    ebx
  3420.           End;
  3421. (* -------------------------------------------------------- *)
  3422. {76.1.4}  Function  GetIPv4DNS(Device: Byte): Dword; StdCall;
  3423.           Asm
  3424.                   push   ebx
  3425.                   mov    eax, 76
  3426.                   mov    ebx, $00010000
  3427.                   mov    bl, 4
  3428.                   mov    bh, Device
  3429.                   int    64
  3430.                   pop    ebx
  3431.           End;
  3432. (* -------------------------------------------------------- *)
  3433. {76.1.5}  Function  SetIPv4DNS(Device: Byte; DNS: Dword): Dword; StdCall;
  3434.           Asm
  3435.                   push   ebx
  3436.                   mov    eax, 76
  3437.                   mov    ebx, $00010000
  3438.                   mov    bl, 5
  3439.                   mov    bh, Device
  3440.                   mov    ecx, DNS
  3441.                   int    64
  3442.                   pop    ebx
  3443.           End;
  3444. (* -------------------------------------------------------- *)
  3445. {76.1.6}  Function  GetIPv4Subnet(Device: Byte): Dword; StdCall;
  3446.           Asm
  3447.                   push   ebx
  3448.                   mov    eax, 76
  3449.                   mov    ebx, $00010000
  3450.                   mov    bl, 6
  3451.                   mov    bh, Device
  3452.                   int    64
  3453.                   pop    ebx
  3454.           End;
  3455. (* -------------------------------------------------------- *)
  3456. {76.1.7}  Function  SetIPv4Subnet(Device: Byte; Subnet: Dword): Dword; StdCall;
  3457.           Asm
  3458.                   push   ebx
  3459.                   mov    eax, 76
  3460.                   mov    ebx, $00010000
  3461.                   mov    bl, 7
  3462.                   mov    bh, Device
  3463.                   mov    ecx, Subnet
  3464.                   int    64
  3465.                   pop    ebx
  3466.           End;
  3467. (* -------------------------------------------------------- *)
  3468. {76.1.8}  Function  GetIPv4Gateway(Device: Byte): Dword; StdCall;
  3469.           Asm
  3470.                   push   ebx
  3471.                   mov    eax, 76
  3472.                   mov    ebx, $00010000
  3473.                   mov    bl, 8
  3474.                   mov    bh, Device
  3475.                   int    64
  3476.                   pop    ebx
  3477.           End;
  3478. (* -------------------------------------------------------- *)
  3479. {76.1.9}  Function  SetIPv4Gateway(Device: Byte; Gateway: Dword): Dword; StdCall;
  3480.           Asm
  3481.                   push   ebx
  3482.                   mov    eax, 76
  3483.                   mov    ebx, $00010000
  3484.                   mov    bl, 9
  3485.                   mov    bh, Device
  3486.                   mov    ecx, Gateway
  3487.                   int    64
  3488.                   pop    ebx
  3489.           End;
  3490. (* -------------------------------------------------------- *)
  3491. {76.2.0}  Function  GetICMPSentPackets(Device: Byte): Dword; StdCall;
  3492.           Asm
  3493.                   push   ebx
  3494.                   mov    eax, 76
  3495.                   mov    ebx, $00020000
  3496.                   mov    bl, 0
  3497.                   mov    bh, Device
  3498.                   int    64
  3499.                   pop    ebx
  3500.           End;
  3501. (* -------------------------------------------------------- *)
  3502. {76.2.1}  Function  GetICMPReceivedPackets(Device: Byte): Dword; StdCall;
  3503.           Asm
  3504.                   push   ebx
  3505.                   mov    eax, 76
  3506.                   mov    ebx, $00020000
  3507.                   mov    bl, 1
  3508.                   mov    bh, Device
  3509.                   int    64
  3510.                   pop    ebx
  3511.           End;
  3512. (* -------------------------------------------------------- *)
  3513. {76.3.0}  Function  GetUDPSentPackets(Device: Byte): Dword; StdCall;
  3514.           Asm
  3515.                   push   ebx
  3516.                   mov    eax, 76
  3517.                   mov    ebx, $00030000
  3518.                   mov    bl, 0
  3519.                   mov    bh, Device
  3520.                   int    64
  3521.                   pop    ebx
  3522.           End;
  3523. (* -------------------------------------------------------- *)
  3524. {76.3.1}  Function  GetUDPReceivedPackets(Device: Byte): Dword; StdCall;
  3525.           Asm
  3526.                   push   ebx
  3527.                   mov    eax, 76
  3528.                   mov    ebx, $00030000
  3529.                   mov    bl, 1
  3530.                   mov    bh, Device
  3531.                   int    64
  3532.                   pop    ebx
  3533.           End;
  3534. (* -------------------------------------------------------- *)
  3535. {76.4.0}  Function  GetTCPSentPackets(Device: Byte): Dword; StdCall;
  3536.           Asm
  3537.                   push   ebx
  3538.                   mov    eax, 76
  3539.                   mov    ebx, $00040000
  3540.                   mov    bl, 0
  3541.                   mov    bh, Device
  3542.                   int    64
  3543.                   pop    ebx
  3544.           End;
  3545. (* -------------------------------------------------------- *)
  3546. {76.4.1}  Function  GetTCPReceivedPackets(Device: Byte): Dword; StdCall;
  3547.           Asm
  3548.                   push   ebx
  3549.                   mov    eax, 76
  3550.                   mov    ebx, $00040000
  3551.                   mov    bl, 1
  3552.                   mov    bh, Device
  3553.                   int    64
  3554.                   pop    ebx
  3555.           End;
  3556. (* -------------------------------------------------------- *)
  3557. {76.5.0}  Function  GetARPSentPackets(Device: Byte): Dword; StdCall;
  3558.           Asm
  3559.                   push   ebx
  3560.                   mov    eax, 76
  3561.                   mov    ebx, $00050000
  3562.                   mov    bl, 0
  3563.                   mov    bh, Device
  3564.                   int    64
  3565.                   pop    ebx
  3566.           End;
  3567. (* -------------------------------------------------------- *)
  3568. {76.5.1}  Function  GetARPReceivedPackets(Device: Byte): Dword; StdCall;
  3569.           Asm
  3570.                   push   ebx
  3571.                   mov    eax, 76
  3572.                   mov    ebx, $00050000
  3573.                   mov    bl, 1
  3574.                   mov    bh, Device
  3575.                   int    64
  3576.                   pop    ebx
  3577.           End;
  3578. (* -------------------------------------------------------- *)
  3579. {76.5.2}  Function  GetARPEntrys(Device: Byte): Dword; StdCall;
  3580.           Asm
  3581.                   push   ebx
  3582.                   mov    eax, 76
  3583.                   mov    ebx, $00050000
  3584.                   mov    bl, 2
  3585.                   mov    bh, Device
  3586.                   int    64
  3587.                   pop    ebx
  3588.           End;
  3589. (* -------------------------------------------------------- *)
  3590. {76.5.3}  Function  GetARPEntry(Device: Byte; Entry: Dword; Var Buffer): Dword; StdCall;
  3591.           Asm
  3592.                   push   ebx
  3593.                   push   edi
  3594.                   mov    eax, 76
  3595.                   mov    ebx, $00050000
  3596.                   mov    bl, 3
  3597.                   mov    bh, Device
  3598.                   mov    ecx, Entry
  3599.                   mov    edi, Buffer
  3600.                   int    64
  3601.                   pop    edi
  3602.                   pop    ebx
  3603.           End;
  3604. (* -------------------------------------------------------- *)
  3605. {76.5.4}  Function  AddARPEntry(Device: Byte; Const Buffer): Dword; StdCall;
  3606.           Asm
  3607.                   push   ebx
  3608.                   push   esi
  3609.                   mov    eax, 76
  3610.                   mov    ebx, $00050000
  3611.                   mov    bl, 4
  3612.                   mov    bh, Device
  3613.                   mov    esi, Buffer
  3614.                   int    64
  3615.                   pop    esi
  3616.                   pop    ebx
  3617.           End;
  3618. (* -------------------------------------------------------- *)
  3619. {76.5.5}  Function  RemoveARPEntry(Device: Byte; Entry: Dword): Dword; StdCall;
  3620.           Asm
  3621.                   push   ebx
  3622.                   mov    eax, 76
  3623.                   mov    ebx, $00050000
  3624.                   mov    bl, 5
  3625.                   mov    bh, Device
  3626.                   mov    ecx, Entry
  3627.                   int    64
  3628.                   pop    ebx
  3629.           End;
  3630. (* -------------------------------------------------------- *)
  3631. {76.5.6}  Function  SendARPAnnounce(Device: Byte): Dword; StdCall;
  3632.           Asm
  3633.                   push   ebx
  3634.                   mov    eax, 76
  3635.                   mov    ebx, $00050000
  3636.                   mov    bl, 6
  3637.                   mov    bh, Device
  3638.                   int    64
  3639.                   pop    ebx
  3640.           End;
  3641. (* -------------------------------------------------------- *)
  3642. {76.5.7}  Function  GetARPConflicts(Device: Byte): Dword; StdCall;
  3643.           Asm
  3644.                   push   ebx
  3645.                   mov    eax, 76
  3646.                   mov    ebx, $00050000
  3647.                   mov    bl, 7
  3648.                   mov    bh, Device
  3649.                   int    64
  3650.                   pop    ebx
  3651.           End;
  3652. (* -------------------------------------------------------- *)
  3653. {77.0}    Function  CreateFutex(Futex: Pointer): Dword; StdCall;
  3654.           Asm
  3655.                   push   ebx
  3656.                   mov    eax, 77
  3657.                   mov    ebx, 0
  3658.                   mov    ecx, Futex
  3659.                   int    64
  3660.                   pop    ebx
  3661.           End;
  3662. (* -------------------------------------------------------- *)
  3663. {77.1}    Function  DestroyFutex(Handle: Dword): Dword; StdCall;
  3664.           Asm
  3665.                   push   ebx
  3666.                   mov    eax, 77
  3667.                   mov    ebx, 1
  3668.                   mov    ecx, Handle
  3669.                   int    64
  3670.                   pop    ebx
  3671.           End;
  3672. (* -------------------------------------------------------- *)
  3673. {77.2}    Function  WaitFutex(Handle, Value, Time: Dword): Dword; StdCall;
  3674.           Asm
  3675.                   push   ebx
  3676.                   push   esi
  3677.                   mov    eax, 77
  3678.                   mov    ebx, 2
  3679.                   mov    ecx, Handle
  3680.                   mov    edx, Value
  3681.                   mov    esi, Time
  3682.                   int    64
  3683.                   pop    esi
  3684.                   pop    ebx
  3685.           End;
  3686. (* -------------------------------------------------------- *)
  3687. {77.3}    Function  WakeFutex(Handle, Waiters: Dword): Dword; StdCall;
  3688.           Asm
  3689.                   push   ebx
  3690.                   mov    eax, 77
  3691.                   mov    ebx, 3
  3692.                   mov    ecx, Handle
  3693.                   mov    edx, Waiters
  3694.                   int    64
  3695.                   pop    ebx
  3696.           End;
  3697. (* -------------------------------------------------------- *)
  3698.           Function  GetProcAddress(hLib: Pointer; ProcName: PChar): Pointer; StdCall;
  3699.           Asm
  3700.                   push   esi
  3701.                   push   edi
  3702.                   push   ebx
  3703.                   mov    edx, hLib
  3704.                   xor    eax, eax
  3705.                   test   edx, edx
  3706.                   jz     @end
  3707.                   mov    edi, ProcName
  3708.                   mov    ecx, $FFFFFFFF
  3709.                   repne scasb
  3710.                   mov    ebx, ecx
  3711.                   not    ebx
  3712.           @next:
  3713.                   mov    esi, [edx]
  3714.                   test   esi, esi
  3715.                   jz     @end
  3716.                   mov    ecx, ebx
  3717.                   mov    edi, ProcName
  3718.                   add    edx, 8
  3719.                   repe cmpsb
  3720.                   jne    @next
  3721.                   mov    eax, [edx - 4]
  3722.           @end:
  3723.                   pop    ebx
  3724.                   pop    edi
  3725.                   pop    esi
  3726.           End;
  3727. (* -------------------------------------------------------- *)
  3728. End.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement