ultimatepp/reference/WebImage/main.cpp
cxl 05252bf8b6 reference/WebImage: Changed to use HttpRequest
git-svn-id: svn://ultimatepp.org/upp/trunk@5380 f0d560ea-af0d-0410-9eb7-867de7ffcac7
2012-09-22 08:00:15 +00:00

21 lines
335 B
C++

#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();
}