reference/WebImage: Changed to use HttpRequest

git-svn-id: svn://ultimatepp.org/upp/trunk@5380 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2012-09-22 08:00:15 +00:00
parent 2d06c1ad64
commit e448348db9

View file

@ -1,22 +1,21 @@
#include <CtrlLib/CtrlLib.h>
#include <Web/Web.h>
using namespace Upp;
struct MyApp : TopWindow {
Image img;
virtual void Paint(Draw& w) {
w.DrawRect(GetSize(), Gray());
w.DrawImage(0, 0, img);
}
MyApp() {
img = StreamRaster::LoadStringAny(HttpClientGet("http://www.ultimatepp.org/1i.png"));
}
};
GUI_APP_MAIN
{
MyApp().Run();
}
#include <CtrlLib/CtrlLib.h>
using namespace Upp;
struct MyApp : TopWindow {
Image img;
virtual void Paint(Draw& w) {
w.DrawRect(GetSize(), Gray());
w.DrawImage(0, 0, img);
}
MyApp() {
img = StreamRaster::LoadStringAny(HttpRequest("http://www.ultimatepp.org/1i.png").Execute());
}
};
GUI_APP_MAIN
{
MyApp().Run();
}