dirdlg.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /////////////////////////////////////////////////////////////////////////////
  2. // Name: wx/gtk/dirdlg.h
  3. // Purpose: wxDirDialog
  4. // Author: Francesco Montorsi
  5. // Copyright: (c) 2006 Francesco Montorsi
  6. // Licence: wxWindows licence
  7. /////////////////////////////////////////////////////////////////////////////
  8. #ifndef __GTKDIRDLGH__
  9. #define __GTKDIRDLGH__
  10. //-------------------------------------------------------------------------
  11. // wxDirDialog
  12. //-------------------------------------------------------------------------
  13. class WXDLLIMPEXP_CORE wxDirDialog : public wxDirDialogBase
  14. {
  15. public:
  16. wxDirDialog() { }
  17. wxDirDialog(wxWindow *parent,
  18. const wxString& message = wxDirSelectorPromptStr,
  19. const wxString& defaultPath = wxEmptyString,
  20. long style = wxDD_DEFAULT_STYLE,
  21. const wxPoint& pos = wxDefaultPosition,
  22. const wxSize& size = wxDefaultSize,
  23. const wxString& name = wxDirDialogNameStr);
  24. bool Create(wxWindow *parent,
  25. const wxString& message = wxDirSelectorPromptStr,
  26. const wxString& defaultPath = wxEmptyString,
  27. long style = wxDD_DEFAULT_STYLE,
  28. const wxPoint& pos = wxDefaultPosition,
  29. const wxSize& size = wxDefaultSize,
  30. const wxString& name = wxDirDialogNameStr);
  31. virtual ~wxDirDialog() { }
  32. public: // overrides from wxGenericDirDialog
  33. wxString GetPath() const;
  34. void SetPath(const wxString& path);
  35. // Implementation only.
  36. void GTKOnAccept();
  37. void GTKOnCancel();
  38. protected:
  39. // override this from wxTLW since the native
  40. // form doesn't have any m_wxwindow
  41. virtual void DoSetSize(int x, int y,
  42. int width, int height,
  43. int sizeFlags = wxSIZE_AUTO);
  44. private:
  45. wxString m_selectedDirectory;
  46. DECLARE_DYNAMIC_CLASS(wxDirDialog)
  47. };
  48. #endif // __GTKDIRDLGH__