mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 23:39:24 +02:00
FpWeb: call New HTTP Application options dialog in DoInitDescriptor callback instead of InitProject in order to avoid closing current project when the options form was just shown (current project should only be closed when user presses OK button in the options form)
This commit is contained in:
parent
5aee55a625
commit
897f7280cb
@ -200,6 +200,7 @@ type
|
|||||||
function GetOptions: TModalResult;
|
function GetOptions: TModalResult;
|
||||||
public
|
public
|
||||||
constructor Create; override;
|
constructor Create; override;
|
||||||
|
function DoInitDescriptor: TModalResult; override;
|
||||||
function GetLocalizedName: string; override;
|
function GetLocalizedName: string; override;
|
||||||
function GetLocalizedDescription: string; override;
|
function GetLocalizedDescription: string; override;
|
||||||
function InitProject(AProject: TLazProject): TModalResult; override;
|
function InitProject(AProject: TLazProject): TModalResult; override;
|
||||||
@ -856,6 +857,11 @@ begin
|
|||||||
Name:='FPHTTPApplication';
|
Name:='FPHTTPApplication';
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function THTTPApplicationDescriptor.DoInitDescriptor: TModalResult;
|
||||||
|
begin
|
||||||
|
Result:=GetOptions;
|
||||||
|
end;
|
||||||
|
|
||||||
function THTTPApplicationDescriptor.GetLocalizedName: string;
|
function THTTPApplicationDescriptor.GetLocalizedName: string;
|
||||||
begin
|
begin
|
||||||
Result:=rsHTTPAppli;
|
Result:=rsHTTPAppli;
|
||||||
@ -899,9 +905,6 @@ Var
|
|||||||
|
|
||||||
begin
|
begin
|
||||||
inherited InitProject(AProject);
|
inherited InitProject(AProject);
|
||||||
Result:=GetOptions;
|
|
||||||
if Result<>mrOK then
|
|
||||||
Exit;
|
|
||||||
MainFile:=AProject.CreateProjectFile('httpproject1.lpr');
|
MainFile:=AProject.CreateProjectFile('httpproject1.lpr');
|
||||||
MainFile.IsPartOfProject:=true;
|
MainFile.IsPartOfProject:=true;
|
||||||
AProject.AddFile(MainFile,false);
|
AProject.AddFile(MainFile,false);
|
||||||
|
Loading…
Reference in New Issue
Block a user