]>
git.saurik.com Git - wxWidgets.git/blob - src/palmos/dirdlg.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/palmos/dirdlg.cpp
3 // Purpose: wxDirDialog
4 // Author: William Osborne - minimal working wxPalmOS port
8 // Copyright: (c) William Osborne
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 // ============================================================================
14 // ============================================================================
16 // ----------------------------------------------------------------------------
18 // ----------------------------------------------------------------------------
20 // For compilers that support precompilation, includes "wx.h".
21 #include "wx/wxprec.h"
29 #if defined(__WIN95__) && !defined(__GNUWIN32_OLD__) && wxUSE_OLE
33 #include "wx/dialog.h"
34 #include "wx/dirdlg.h"
36 #include "wx/app.h" // for GetComCtl32Version()
39 #include "wx/palmos/private.h"
41 // ----------------------------------------------------------------------------
43 // ----------------------------------------------------------------------------
46 #define MAX_PATH 4096 // be generous
49 #ifndef BIF_NEWDIALOGSTYLE
50 #define BIF_NEWDIALOGSTYLE 0x0040
53 #ifndef BIF_NONEWFOLDERBUTTON
54 #define BIF_NONEWFOLDERBUTTON 0x0200
58 #define BIF_EDITBOX 16
61 // ----------------------------------------------------------------------------
63 // ----------------------------------------------------------------------------
65 IMPLEMENT_CLASS(wxDirDialog
, wxDialog
)
67 // ----------------------------------------------------------------------------
68 // private functions prototypes
69 // ----------------------------------------------------------------------------
72 static void ItemListFree(LPITEMIDLIST pidl
);
74 // the callback proc for the dir dlg
75 static int CALLBACK
BrowseCallbackProc(HWND hwnd
, UINT uMsg
, LPARAM lp
,
79 // ============================================================================
81 // ============================================================================
83 // ----------------------------------------------------------------------------
85 // ----------------------------------------------------------------------------
87 wxDirDialog::wxDirDialog(wxWindow
*parent
,
88 const wxString
& message
,
89 const wxString
& defaultPath
,
91 const wxPoint
& WXUNUSED(pos
),
92 const wxSize
& WXUNUSED(size
),
93 const wxString
& WXUNUSED(name
))
97 void wxDirDialog::SetPath(const wxString
& path
)
101 int wxDirDialog::ShowModal()
106 // ----------------------------------------------------------------------------
108 // ----------------------------------------------------------------------------
111 BrowseCallbackProc(HWND hwnd
, UINT uMsg
, LPARAM lp
, LPARAM pData
)
117 static void ItemListFree(LPITEMIDLIST pidl
)
122 SHGetMalloc(&pMalloc
);
130 wxLogLastError(wxT("SHGetMalloc"));
136 #include "../generic/dirdlgg.cpp"
137 #endif // compiler/platform on which the code here compiles
139 #endif // wxUSE_DIRDLG