mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2025-06-02 21:57:37 +02:00
ResponseFilterBrowser now downloads the resource 1 time after the user clicks the GO button
This commit is contained in:
parent
8000e45198
commit
ee61ac3c7b
@ -50,7 +50,7 @@ object ResponseFilterBrowserFrm: TResponseFilterBrowserFrm
|
|||||||
Margins.Right = 5
|
Margins.Right = 5
|
||||||
Align = alClient
|
Align = alClient
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
Text = 'https://www.briskbard.com'
|
Text = 'https://www.wikipedia.org/'
|
||||||
ExplicitHeight = 21
|
ExplicitHeight = 21
|
||||||
end
|
end
|
||||||
object Panel1: TPanel
|
object Panel1: TPanel
|
||||||
@ -88,7 +88,7 @@ object ResponseFilterBrowserFrm: TResponseFilterBrowserFrm
|
|||||||
Height = 20
|
Height = 20
|
||||||
Align = alRight
|
Align = alRight
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
Text = 'script.js'
|
Text = 'index-475f3bca23.js'
|
||||||
ExplicitHeight = 21
|
ExplicitHeight = 21
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -298,7 +298,7 @@ var
|
|||||||
TempHeader : string;
|
TempHeader : string;
|
||||||
TempLen : integer;
|
TempLen : integer;
|
||||||
begin
|
begin
|
||||||
if (response <> nil) and IsMyResource(request) then
|
if not(FRscCompleted) and (response <> nil) and IsMyResource(request) then
|
||||||
begin
|
begin
|
||||||
Result := FFilter;
|
Result := FFilter;
|
||||||
TempHeader := trim(response.GetHeader('Content-Length'));
|
TempHeader := trim(response.GetHeader('Content-Length'));
|
||||||
@ -398,7 +398,6 @@ begin
|
|||||||
|
|
||||||
FStream.Clear;
|
FStream.Clear;
|
||||||
FRscSize := -1;
|
FRscSize := -1;
|
||||||
FRscCompleted := False;
|
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
Memo1.Lines.Clear;
|
Memo1.Lines.Clear;
|
||||||
@ -409,6 +408,7 @@ end;
|
|||||||
|
|
||||||
procedure TResponseFilterBrowserFrm.GoBtnClick(Sender: TObject);
|
procedure TResponseFilterBrowserFrm.GoBtnClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
FRscCompleted := False;
|
||||||
Chromium1.LoadURL(AddressEdt.Text);
|
Chromium1.LoadURL(AddressEdt.Text);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user