ultimatepp/upptst/FileSelLazyIcon/main.cpp
cxl 6bf7d66f02 .upptst
git-svn-id: svn://ultimatepp.org/upp/trunk@13679 f0d560ea-af0d-0410-9eb7-867de7ffcac7
2019-11-05 18:00:08 +00:00

18 lines
331 B
C++

#include <CtrlLib/CtrlLib.h>
#include <plugin/jpg/jpg.h>
using namespace Upp;
static void sLoadImage(const String& path, Image& result)
{
result = StreamRaster::LoadFileAny(path);
}
GUI_APP_MAIN
{
FileSel fs;
fs.AllFilesType();
fs.Type("Text", "*.txt");
fs.WhenIconLazy = sLoadImage;
fs.ExecuteOpen();
}