-
Notifications
You must be signed in to change notification settings - Fork 11
/
commontypes.pas
53 lines (48 loc) · 1.98 KB
/
commontypes.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
unit commontypes;
{****************************************************************
****************************************************************
*** This file belongs to PVIEW/PSKILL ***
*** Copyright (c) 2001 by -=Assarbad [GoP]=- ***
*** ____________ ___________ ***
*** /\ ________\ /\ _____ \ ***
*** / \ \ / __________/ \ \ \ \ ***
*** \ \ \ __/___ /\ _____ \ \ \____\ \ ***
*** \ \ \ /\___ \ \ \ \ \ \ _______\ ***
*** \ \ \ / \ \ \ \ \ \ \ \ / ***
*** \ \ \_____\ \ \ \____\ \ \ \____/ ***
*** \ \___________\ \__________\ \__\ ***
*** \ / / / / / / ***
*** \/___________/ \/__________/ \/__/ ***
*** ***
*** May the source be with you, stranger ... :-) ***
*** ***
*** Greets from -=Assarbad [GoP]=- ... ***
*** Special greets go 2 Nico, Casper, SA, Pizza, Navarion...***
***[for questions/proposals drop a mail to [email protected]]***
*****************************************ASCII by Assa [GoP]****
****************************************************************}
interface
{$mode delphi}{$h+}
uses windows,
sysutils;
TYPE
TProcessrec = RECORD
name: STRING;
PID: DWORD;
END;
TProcessrecs = ARRAY OF TProcessrec;
implementation
FUNCTION MAKELANGID(PRI, SUB: WORD): integer;
BEGIN
result := (SUB SHL 10) OR PRI;
END;
FUNCTION frmt(mformat: STRING; args: ARRAY OF POINTER): STRING;
VAR
bla: pchar;
BEGIN
getmem(bla, 1024 * 2 + 2);
wvsprintf(bla, pchar(mformat), pchar(@args));
result := STRING(bla);
freemem(bla, 1024 * 2 + 2);
END;
end.