diff options
author | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
---|---|---|
committer | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
commit | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch) | |
tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Wasabi/api/util/selectfile.h | |
parent | 537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff) | |
download | winamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz |
Initial community commit
Diffstat (limited to 'Src/Wasabi/api/util/selectfile.h')
-rw-r--r-- | Src/Wasabi/api/util/selectfile.h | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/Src/Wasabi/api/util/selectfile.h b/Src/Wasabi/api/util/selectfile.h new file mode 100644 index 00000000..5dc378a7 --- /dev/null +++ b/Src/Wasabi/api/util/selectfile.h @@ -0,0 +1,41 @@ +#ifndef _SELECTFILE_H +#define _SELECTFILE_H + +#include <bfc/common.h> + +#include <bfc/ptrlist.h> +#include <bfc/string/StringW.h> + +class svc_fileSelector; +class ifc_window; + +class SelectFile +{ +public: + SelectFile(ifc_window *parent, const wchar_t *menu_prefix = NULL, const wchar_t *menu_suffix = NULL); + ~SelectFile(); + + void setDefaultDir(const wchar_t *dir); // default dir to use + const wchar_t *getDirectory(); // return base directory after ok clicked + void setIdent(const wchar_t *id); // unless you saved one under this id + + void setPopPosition(int x, int y); // in screen coords + + int runSelector(const wchar_t *type = NULL, int allow_multiple = FALSE, const wchar_t *extlist = NULL); // if NULL, generate popup + const wchar_t *getType(); + + int getNumFiles(); + const wchar_t *enumFilename(int n); + +private: + int xpos, ypos; + int pos_set; + ifc_window *parentWnd; + svc_fileSelector *svc; + PtrList<StringW> types; + StringW prefix_str, suffix_str; + StringW default_dir, ident; + StringW saved_type; +}; + +#endif |