savefile.h 775 B

12345678910111213141516171819202122232425262728293031
  1. #ifndef _SAVEFILE_H
  2. #define _SAVEFILE_H
  3. #include "common.h"
  4. #include "modal.h"
  5. #include "../bfc/string.h"
  6. class ifc_window;
  7. class SaveFileWnd : public Modal {
  8. public:
  9. SaveFileWnd(const char *ident=NULL);
  10. /**
  11. Sets the initial directory for the picker. If force is FALSE, this directory
  12. will only be used if no previous directory has been saved for the indent.
  13. If TRUE, it will always be used.
  14. */
  15. void setInitialDir(const char *dir, int force=FALSE);
  16. int getSaveFile(ifc_window *parent, const char *ext, const char *suggext);
  17. int getSaveFileW(ifc_window *parent, const char *ext, const char *suggext);
  18. const char *getFilename() { return filename; }
  19. private:
  20. String identifier;
  21. String filename;
  22. String initial_dir;
  23. int force_initial_dir;
  24. };
  25. #endif