wxdirpickerctrlthis control allows the user to select a directory. the generic implementation is a button which brings up a wxdirdialog when clicked. native implementation may differ but this is usually a (small) widget which give access to the dir-chooser dialog. it is only available if wxuse_dirpickerctrl is set to 1 (the default). derived from
wxpickerbase include files <wx/filepicker.h> window styles
event handling to process a directory picker event, use these event handler macros to direct input to member functions that take a wxfiledirpickerevent argument.
see also
wxdirdialog, members
wxdirpickerctrl::wxdirpickerctrl
wxdirpickerctrl::wxdirpickerctrlwxdirpickerctrl(wxwindow *parent, wxwindowid id, const wxstring& path = wxemptystring, const wxstring& message = "select a folder", const wxpoint& pos = wxdefaultposition, const wxsize& size = wxdefaultsize, long style = wxdirp_default_style, const wxvalidator& validator = wxdefaultvalidator, const wxstring& name = "dirpickerctrl") initializes the object and calls create with all the parameters.
wxdirpickerctrl::createbool create(wxwindow *parent, wxwindowid id, const wxstring& path = wxemptystring, const wxstring& message = "select a folder", const wxpoint& pos = wxdefaultposition, const wxsize& size = wxdefaultsize, long style = wxdirp_default_style, const wxvalidator& validator = wxdefaultvalidator, const wxstring& name = "dirpickerctrl") parameters parent
id
path
message
pos
size
style
validator
name
return value true if the control was successfully created or false if creation failed.
wxdirpickerctrl::getpathwxstring getpath() const returns the absolute path of the currently selected directory.
wxdirpickerctrl::setpathvoid setpath(const wxstring &dirname) sets the absolute path of the currently selected directory. this must be a valid directory if wxdirp_dir_must_exist style was given.
|