mirror of
https://github.com/vapaamies/KolibriOS.git
synced 2025-02-03 09:32:06 +01:00
Example projects made compilable by any version of Delphi
This commit is contained in:
parent
db03f7a14a
commit
743e32c30b
1
.gitignore
vendored
1
.gitignore
vendored
@ -10,3 +10,4 @@
|
|||||||
*.dsk
|
*.dsk
|
||||||
*.exe
|
*.exe
|
||||||
*.map
|
*.map
|
||||||
|
*.tmp
|
@ -5,9 +5,9 @@ uses
|
|||||||
|
|
||||||
var
|
var
|
||||||
hConsole: Pointer;
|
hConsole: Pointer;
|
||||||
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PChar); stdcall;
|
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PKolibriChar); stdcall;
|
||||||
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
||||||
Printf: function(const Format: PChar): Integer; cdecl varargs;
|
Printf: function(const Format: PKolibriChar): Integer; cdecl varargs;
|
||||||
GetConsoleCursorPos: procedure(X, Y: PInteger); stdcall;
|
GetConsoleCursorPos: procedure(X, Y: PInteger); stdcall;
|
||||||
SetConsoleCursorPos: procedure(X, Y: Integer); stdcall;
|
SetConsoleCursorPos: procedure(X, Y: Integer); stdcall;
|
||||||
kbhit: function: Boolean;
|
kbhit: function: Boolean;
|
||||||
|
@ -4,7 +4,7 @@ uses
|
|||||||
KolibriOS;
|
KolibriOS;
|
||||||
|
|
||||||
const
|
const
|
||||||
AppPath = PPChar(32);
|
AppPath = PPKolibriChar(32);
|
||||||
|
|
||||||
type
|
type
|
||||||
THeader = packed record
|
THeader = packed record
|
||||||
@ -27,7 +27,7 @@ type
|
|||||||
Header: THeader;
|
Header: THeader;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure ExtractFileDirectory(Source, Dest: PChar); stdcall;
|
procedure ExtractFileDirectory(Source, Dest: PKolibriChar); stdcall;
|
||||||
asm
|
asm
|
||||||
PUSH ESI
|
PUSH ESI
|
||||||
PUSH EDI
|
PUSH EDI
|
||||||
@ -65,7 +65,7 @@ begin
|
|||||||
TargaFile := LoadFile('Lena.tga', FileSize);
|
TargaFile := LoadFile('Lena.tga', FileSize);
|
||||||
|
|
||||||
with TargaFile^ do
|
with TargaFile^ do
|
||||||
Image := Pointer(PChar(TargaFile) + SizeOf(Header) + Header.IDLength);
|
Image := Pointer(PKolibriChar(TargaFile) + SizeOf(Header) + Header.IDLength);
|
||||||
|
|
||||||
with GetScreenSize do
|
with GetScreenSize do
|
||||||
begin
|
begin
|
||||||
|
@ -4,7 +4,7 @@ uses
|
|||||||
KolibriOS;
|
KolibriOS;
|
||||||
|
|
||||||
const
|
const
|
||||||
AppPath = PPChar(32);
|
AppPath = PPKolibriChar(32);
|
||||||
|
|
||||||
Picture1 = 'Flower(4bpp).bmp';
|
Picture1 = 'Flower(4bpp).bmp';
|
||||||
Picture2 = 'Mario(1bpp).bmp';
|
Picture2 = 'Mario(1bpp).bmp';
|
||||||
@ -47,7 +47,7 @@ type
|
|||||||
Palette: array[0..0] of TRGBQuad;
|
Palette: array[0..0] of TRGBQuad;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure ExtractFileDirectory(Src, Dst: PChar); stdcall;
|
procedure ExtractFileDirectory(Src, Dst: PKolibriChar); stdcall;
|
||||||
asm
|
asm
|
||||||
PUSH ESI
|
PUSH ESI
|
||||||
PUSH EDI
|
PUSH EDI
|
||||||
|
@ -4,16 +4,16 @@ uses
|
|||||||
KolibriOS;
|
KolibriOS;
|
||||||
|
|
||||||
const
|
const
|
||||||
AppPath = PPChar(32);
|
AppPath = PPKolibriChar(32);
|
||||||
CmdLine = PPChar(28);
|
CmdLine = PPKolibriChar(28);
|
||||||
|
|
||||||
BUFFER_SIZE = 256;
|
BUFFER_SIZE = 256;
|
||||||
|
|
||||||
var
|
var
|
||||||
hConsole: Pointer;
|
hConsole: Pointer;
|
||||||
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PChar); stdcall;
|
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PKolibriChar); stdcall;
|
||||||
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
||||||
printf: function(const Format: PChar): Integer; cdecl varargs;
|
printf: function(const Format: PKolibriChar): Integer; CDecl varargs;
|
||||||
|
|
||||||
Buffer: array[0..BUFFER_SIZE - 1] of Char;
|
Buffer: array[0..BUFFER_SIZE - 1] of Char;
|
||||||
|
|
||||||
|
@ -5,9 +5,9 @@ uses
|
|||||||
|
|
||||||
var
|
var
|
||||||
hConsole: Pointer;
|
hConsole: Pointer;
|
||||||
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PChar); stdcall;
|
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PKolibriChar); stdcall;
|
||||||
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
||||||
WriteN: procedure(Str: PChar; Count: LongWord); stdcall;
|
WriteN: procedure(Str: PKolibriChar; Count: LongWord); stdcall;
|
||||||
|
|
||||||
FileSize: LongWord;
|
FileSize: LongWord;
|
||||||
Buffer: Pointer;
|
Buffer: Pointer;
|
||||||
|
@ -5,9 +5,9 @@ uses
|
|||||||
|
|
||||||
var
|
var
|
||||||
hConsole: Pointer;
|
hConsole: Pointer;
|
||||||
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PChar); stdcall;
|
ConsoleInit: procedure(WndWidth, WndHeight, ScrWidth, ScrHeight: LongWord; Caption: PKolibriChar); stdcall;
|
||||||
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
ConsoleExit: procedure(bCloseWindow: Cardinal); stdcall;
|
||||||
printf: function(const Format: PChar): Integer; cdecl varargs;
|
printf: function(const Format: PKolibriChar): Integer; cdecl varargs;
|
||||||
|
|
||||||
const
|
const
|
||||||
FolderPath = '/sys';
|
FolderPath = '/sys';
|
||||||
|
@ -4,7 +4,7 @@ uses
|
|||||||
KolibriOS;
|
KolibriOS;
|
||||||
|
|
||||||
const
|
const
|
||||||
AppPath = PPChar(32);
|
AppPath = PPKolibriChar(32);
|
||||||
|
|
||||||
ARROW_BUTTON = 2;
|
ARROW_BUTTON = 2;
|
||||||
POINT_BUTTON = 3;
|
POINT_BUTTON = 3;
|
||||||
@ -39,7 +39,7 @@ type
|
|||||||
BitmapInfoHeader: TBitmapInfoHeader;
|
BitmapInfoHeader: TBitmapInfoHeader;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure ExtractFileDirectory(Src, Dst: PChar); stdcall;
|
procedure ExtractFileDirectory(Src, Dst: PKolibriChar); stdcall;
|
||||||
asm
|
asm
|
||||||
PUSH ESI
|
PUSH ESI
|
||||||
PUSH EDI
|
PUSH EDI
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user