Added wxStandardPaths::MSWGetShellDir().
This function allows to get the location of Windows shell special folders not covered by wxStandardPaths methods (yet), e.g. CSIDL_DESKTOPDIRECTORY. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61662 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -62,6 +62,10 @@ public:
|
|||||||
// Undo the effects of all preceding IgnoreAppSubDir() calls.
|
// Undo the effects of all preceding IgnoreAppSubDir() calls.
|
||||||
void DontIgnoreAppSubDir();
|
void DontIgnoreAppSubDir();
|
||||||
|
|
||||||
|
|
||||||
|
// Returns the directory corresponding to the specified Windows shell CSIDL
|
||||||
|
static wxString MSWGetShellDir(int csidl);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
// get the path corresponding to the given standard CSIDL_XXX constant
|
// get the path corresponding to the given standard CSIDL_XXX constant
|
||||||
static wxString DoGetDirectory(int csidl);
|
static wxString DoGetDirectory(int csidl);
|
||||||
|
@@ -275,6 +275,26 @@ public:
|
|||||||
*/
|
*/
|
||||||
void IgnoreAppBuildSubDirs();
|
void IgnoreAppBuildSubDirs();
|
||||||
|
|
||||||
|
/**
|
||||||
|
Returns location of Windows shell special folder.
|
||||||
|
|
||||||
|
This function is, by definition, MSW-specific. It can be used to access
|
||||||
|
pre-defined shell directories not covered by the existing methods of
|
||||||
|
this class, e.g.:
|
||||||
|
@code
|
||||||
|
#ifdef __WXMSW__
|
||||||
|
// get the location of files waiting to be burned on a CD
|
||||||
|
wxString cdburnArea =
|
||||||
|
wxStandardPaths::MSWGetShellDir(CSIDL_CDBURN_AREA);
|
||||||
|
#endif // __WXMSW__
|
||||||
|
@endcode
|
||||||
|
|
||||||
|
@param csidl
|
||||||
|
|
||||||
|
@since 2.9.1
|
||||||
|
*/
|
||||||
|
static wxString MSWGetShellDir(int csidl);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Lets wxStandardPaths know about the real program installation prefix on a Unix
|
Lets wxStandardPaths know about the real program installation prefix on a Unix
|
||||||
system. By default, the value returned by GetInstallPrefix() is used.
|
system. By default, the value returned by GetInstallPrefix() is used.
|
||||||
|
@@ -321,6 +321,12 @@ void wxStandardPaths::DontIgnoreAppSubDir()
|
|||||||
m_appDir.clear();
|
m_appDir.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* static */
|
||||||
|
wxString wxStandardPaths::MSWGetShellDir(int csidl)
|
||||||
|
{
|
||||||
|
return DoGetDirectory(csidl);
|
||||||
|
}
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// public functions
|
// public functions
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
Reference in New Issue
Block a user