Add GetUserConfigDir

This commit is contained in:
Marek Roszko 2021-01-22 23:35:09 -05:00
parent 2807a37fc0
commit 8622565480
5 changed files with 21 additions and 0 deletions

View File

@ -6,6 +6,7 @@
#include <pgm_base.h>
#include <settings/settings_manager.h>
wxString PATHS::GetUserScriptingPath()
{
wxFileName tmp;

View File

@ -51,4 +51,10 @@ bool KIPLATFORM::ENV::IsNetworkPath( const wxString& aPath )
wxString KIPLATFORM::ENV::GetDocumentsDir()
{
return g_get_user_special_dir( G_USER_DIRECTORY_DOCUMENTS );
}
wxString KIPLATFORM::ENV::GetUserConfigDir()
{
return g_get_user_config_dir();
}

View File

@ -53,5 +53,7 @@ namespace KIPLATFORM
* @return Path for the given aPath
*/
wxString GetDocumentsDir();
wxString GetUserConfigDir();
}
}

View File

@ -63,4 +63,10 @@ bool KIPLATFORM::ENV::IsNetworkPath( const wxString& aPath )
wxString KIPLATFORM::ENV::GetDocumentsDir()
{
return wxStandardPaths::Get().GetDocumentsDir();
}
wxString KIPLATFORM::ENV::GetUserConfigDir()
{
return wxStandardPaths::Get().GetUserConfigDir();
}

View File

@ -55,4 +55,10 @@ bool KIPLATFORM::ENV::IsNetworkPath( const wxString& aPath )
wxString KIPLATFORM::ENV::GetDocumentsDir()
{
return wxStandardPaths::Get().GetDocumentsDir();
}
wxString KIPLATFORM::ENV::GetUserConfigDir()
{
return wxStandardPaths::Get().GetUserConfigDir();
}