.referemce

git-svn-id: svn://ultimatepp.org/upp/trunk@15529 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2020-11-27 21:45:15 +00:00
parent adea4df7e8
commit 8799050700
4 changed files with 7 additions and 6 deletions

View file

@ -1,4 +1,5 @@
#include <CtrlLib/CtrlLib.h>
#include <Core/SSL/SSL.h>
using namespace Upp;

View file

@ -1,7 +1,8 @@
description "Downloads www file directly to disc with GUI response (TcpSocket, HttpRequest demo)\377";
uses
CtrlLib;
CtrlLib,
Core/SSL;
file
main.cpp;

View file

@ -10,8 +10,6 @@ struct Downloader {
FileOut out;
String path;
typedef Downloader CLASSNAME;
void Content(const void *ptr, int size);
void Perform();
void ShowProgress();
@ -23,9 +21,9 @@ struct Downloader {
Downloader::Downloader()
{
http.MaxContentSize(INT_MAX);
http.WhenContent = THISBACK(Content);
http.WhenWait = http.WhenDo = THISBACK(ShowProgress);
http.WhenStart = THISBACK(Start);
http.WhenContent = [=](const void *ptr, int size) { Content(ptr, size); };
http.WhenWait = http.WhenDo = [=] { ShowProgress(); };
http.WhenStart = [=] { Start(); };
}
void Downloader::Start()

View file

@ -1,4 +1,5 @@
#include <Core/Core.h>
#include <Core/SSL/SSL.h>
using namespace Upp;