Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » FileSel&FileList, Path » Preview of FileSel
Preview of FileSel [message #30077] Tue, 07 December 2010 13:12 Go to next message
sevenjay is currently offline  sevenjay
Messages: 30
Registered: October 2008
Location: Taiwan
Member
This is very useful, thanks.
I write an example to help someone quickly understand:
class PreviewImage : public ImageCtrl {
  void SetData(const Value& val)
  {
    String path=val;
    if(!path.IsEmpty())
    {
      SetImage(StreamRaster::LoadFileAny(~path));
      Refresh();
    }
  }
};


 FileSel fileSelIm; 
 PreviewImage img;

 fileSelIm.Type("jpg file", "*.jpg");
 fileSelIm.Preview(img);

Re: Preview of FileSel [message #30082 is a reply to message #30077] Tue, 07 December 2010 14:05 Go to previous message
mirek is currently offline  mirek
Messages: 13442
Registered: November 2005
Ultimate Member
Adapted as reference/FileSelPreview. Thanks.

Mirek
Previous Topic: FileSel: How to get the file name (just saved).
Next Topic: Warning in FileSel
Goto Forum:
  


Current Time: Wed Oct 20 08:26:45 CEST 2021

Total time taken to generate the page: 0.01020 seconds