mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 07:39:22 +02:00
EditorMacroScript: selftest on Mac
git-svn-id: trunk@42616 -
This commit is contained in:
parent
cdf5906d66
commit
465b65079c
@ -4,6 +4,10 @@ unit EMSSelfTest;
|
|||||||
|
|
||||||
interface
|
interface
|
||||||
|
|
||||||
|
{$IFDEF darwin}
|
||||||
|
{$DEFINE NeedTPointFix }
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, SynEdit, SynEditTypes, SynEditKeyCmds, LazLoggerBase,
|
Classes, SysUtils, SynEdit, SynEditTypes, SynEditKeyCmds, LazLoggerBase,
|
||||||
IDECommands, EMScriptClasses, EMScriptMacro, Clipbrd, Dialogs, Controls,
|
IDECommands, EMScriptClasses, EMScriptMacro, Clipbrd, Dialogs, Controls,
|
||||||
@ -45,6 +49,10 @@ var
|
|||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
|
{$IFDEF NeedTPointFix}
|
||||||
|
type TPoint2 = record x,y,a,b,c: Longint; end;
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
{%region RegisterSelfTests}
|
{%region RegisterSelfTests}
|
||||||
|
|
||||||
var
|
var
|
||||||
@ -120,7 +128,7 @@ begin
|
|||||||
TestResultInt2 := AValue.Y;
|
TestResultInt2 := AValue.Y;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function test_getpoint: TPoint;
|
function test_getpoint: {$IFDEF NeedTPointFix}TPoint2{$ELSE}TPoint{$ENDIF};
|
||||||
begin
|
begin
|
||||||
Result.X := TestInputInt1;
|
Result.X := TestInputInt1;
|
||||||
Result.Y := TestInputInt2;
|
Result.Y := TestInputInt2;
|
||||||
@ -192,7 +200,7 @@ const
|
|||||||
Proctest_getbool1: function: Boolean = @test_getbool1;
|
Proctest_getbool1: function: Boolean = @test_getbool1;
|
||||||
Proctest_getbool2: function: Boolean = @test_getbool2;
|
Proctest_getbool2: function: Boolean = @test_getbool2;
|
||||||
Proctest_point: procedure (AValue: TPoint) = @test_point;
|
Proctest_point: procedure (AValue: TPoint) = @test_point;
|
||||||
Proctest_getpoint: function: TPoint = @test_getpoint;
|
Proctest_getpoint: function: {$IFDEF NeedTPointFix}TPoint2{$ELSE}TPoint{$ENDIF} = @test_getpoint;
|
||||||
Proctest_varpoint: procedure (var AValue: TPoint) = @test_varpoint;
|
Proctest_varpoint: procedure (var AValue: TPoint) = @test_varpoint;
|
||||||
Proctest_str1: procedure (AValue: String) = @test_str1;
|
Proctest_str1: procedure (AValue: String) = @test_str1;
|
||||||
Proctest_str2: procedure (AValue: String) = @test_str2;
|
Proctest_str2: procedure (AValue: String) = @test_str2;
|
||||||
|
Loading…
Reference in New Issue
Block a user