mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-01 19:00:41 +01:00
parent
6aad5cc192
commit
f33cec8ed8
@ -882,6 +882,7 @@ Var
|
||||
O : TReportObject;
|
||||
|
||||
begin
|
||||
D:=Default(TRect);
|
||||
Result:=TFPList.Create;
|
||||
try
|
||||
For I:=0 to Count-1 do
|
||||
@ -911,6 +912,7 @@ Var
|
||||
|
||||
begin
|
||||
BL:=Nil;
|
||||
D:=Default(TRect);
|
||||
Result:=TFPList.Create;
|
||||
try
|
||||
try
|
||||
|
||||
@ -344,6 +344,7 @@ Var
|
||||
begin
|
||||
With TSaveDialog.Create(Application) do
|
||||
try
|
||||
DefaultExt:='.json';
|
||||
Filter:='Report files|*.json|All files'+AllFilesMask;
|
||||
Options:=[ofPathMustExist];
|
||||
If Execute then
|
||||
@ -363,20 +364,24 @@ procedure TFPReportComponentEditor.LoadReport;
|
||||
|
||||
Var
|
||||
J : TFPJSONReport;
|
||||
N : String;
|
||||
|
||||
begin
|
||||
With TOpenDialog.Create(Application) do
|
||||
try
|
||||
DefaultExt:='.json';
|
||||
Filter:='Report files|*.json|All files'+AllFilesMask;
|
||||
Options:=[ofFileMustExist];
|
||||
If Execute then
|
||||
If Component is TFPJSONReport then
|
||||
begin
|
||||
N:=J.Name;
|
||||
J:=Component as TFPJSONReport;
|
||||
J.LoadFromFile(FileName);
|
||||
J.DesignTimeJSON.Clear;
|
||||
J.SavetoJSON(J.DesignTimeJSON);
|
||||
end;;
|
||||
J.Name:=N;
|
||||
end;
|
||||
finally
|
||||
Free;
|
||||
end;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user