Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

filedialog.cpp

Go to the documentation of this file.
00001 /*
00002         ClanGUI, copyrights by various people. Have a look in the CREDITS file.
00003         
00004         This sourcecode is distributed using the Library GNU Public Licence,
00005         version 2 or (at your option) any later version. Please read LICENSE
00006         for details.
00007 */
00008 
00009 #include "precomp.h"
00010 #include "API/GUI/filedialog.h"
00011 #include "API/GUI/component_options.h"
00012 #include "API/GUI/stylemanager.h"
00013 #include "filedialog_generic.h"
00014 
00016 // Construction:
00017 
00018 CL_FileDialog::CL_FileDialog(
00019         const CL_ComponentOptions &options,
00020         CL_Component *parent,
00021         CL_StyleManager *style)
00022 :
00023         CL_Component(options, parent, style),
00024         impl(NULL)
00025 {
00026         impl = new CL_FileDialog_Generic(this, options, get_style_manager());
00027         get_style_manager()->connect_styles("filedialog", options, this);
00028 }
00029 
00030 CL_FileDialog::CL_FileDialog(
00031         const std::string &path,
00032         const std::string &filter,
00033         CL_Component *parent,
00034         CL_StyleManager *style)
00035 :
00036         CL_Component(
00037                 CL_FileDialog_Generic::create_options(path, filter),
00038                 parent,
00039                 style),
00040         impl(NULL)
00041 {
00042         CL_ComponentOptions options = CL_FileDialog_Generic::create_options(path, filter);
00043         impl = new CL_FileDialog_Generic(this, options, get_style_manager());
00044         get_style_manager()->connect_styles("filedialog", options, this);
00045 }
00046 
00047 CL_FileDialog::~CL_FileDialog()
00048 {
00049         delete impl;
00050 }
00051 
00053 // Attributes:
00054 
00056 // Operations:
00057 
00058 void CL_FileDialog::set_path(const std::string &path)
00059 {
00060         impl->set_path(path);
00061 }
00062 
00063 void CL_FileDialog::set_filter(const std::string &filter)
00064 {
00065         impl->set_filter(filter);
00066 }
00067 
00069 // Signals:
00070 
00071 CL_Signal_v1<const std::string &> &CL_FileDialog::sig_ok()
00072 {
00073         return impl->sig_ok;
00074 }
00075 
00076 CL_Signal_v0 &CL_FileDialog::sig_cancel()
00077 {
00078         return impl->sig_cancel;
00079 }

Generated at Wed Apr 4 19:54:00 2001 for ClanLib by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001