]> git.saurik.com Git - wxWidgets.git/blame - include/wx/osx/dirdlg.h
Make storing non-trivial data in wxThreadSpecificInfo possible.
[wxWidgets.git] / include / wx / osx / dirdlg.h
CommitLineData
6762286d 1/////////////////////////////////////////////////////////////////////////////
80fdcdb9 2// Name: wx/osx/dirdlg.h
6762286d
SC
3// Purpose: wxDirDialog class
4// Author: Stefan Csomor
5// Modified by:
6// Created: 1998-01-01
6762286d
SC
7// Copyright: (c) Stefan Csomor
8// Licence: wxWindows licence
9/////////////////////////////////////////////////////////////////////////////
10
11#ifndef _WX_DIRDLG_H_
12#define _WX_DIRDLG_H_
13
95c854df
VZ
14#if wxOSX_USE_COCOA
15 DECLARE_WXCOCOA_OBJC_CLASS(NSOpenPanel);
16#endif
17
6762286d
SC
18class WXDLLIMPEXP_CORE wxDirDialog : public wxDirDialogBase
19{
20public:
aad2997b
VZ
21 wxDirDialog() { Init(); }
22
6762286d 23 wxDirDialog(wxWindow *parent,
aad2997b
VZ
24 const wxString& message = wxDirSelectorPromptStr,
25 const wxString& defaultPath = wxT(""),
26 long style = wxDD_DEFAULT_STYLE,
27 const wxPoint& pos = wxDefaultPosition,
28 const wxSize& size = wxDefaultSize,
29 const wxString& name = wxDirDialogNameStr)
30 {
31 Init();
32
33 Create(parent,message,defaultPath,style,pos,size,name);
34 }
35
36 void Create(wxWindow *parent,
6762286d 37 const wxString& message = wxDirSelectorPromptStr,
9a83f860 38 const wxString& defaultPath = wxT(""),
6762286d
SC
39 long style = wxDD_DEFAULT_STYLE,
40 const wxPoint& pos = wxDefaultPosition,
41 const wxSize& size = wxDefaultSize,
42 const wxString& name = wxDirDialogNameStr);
43
681bf55c
SC
44#if wxOSX_USE_COCOA
45 ~wxDirDialog();
46#endif
47
6762286d 48 virtual int ShowModal();
ce00f59b 49
bfa92264
KO
50#if wxOSX_USE_COCOA
51 virtual void ShowWindowModal();
52 virtual void ModalFinishedCallback(void* panel, int returnCode);
ce00f59b 53#endif
6762286d 54
95c854df 55private:
681bf55c 56#if wxOSX_USE_COCOA
95c854df
VZ
57 // Create and initialize NSOpenPanel that we use in both ShowModal() and
58 // ShowWindowModal().
59 WX_NSOpenPanel OSXCreatePanel() const;
60
681bf55c
SC
61 WX_NSObject m_sheetDelegate;
62#endif
95c854df 63
aad2997b
VZ
64 // Common part of all ctors.
65 void Init();
66
95c854df 67 DECLARE_DYNAMIC_CLASS(wxDirDialog)
6762286d
SC
68};
69
95c854df 70#endif // _WX_DIRDLG_H_