mirror of https://github.com/PCSX2/pcsx2.git
macOS: Use standard paths
Most macOS users expect applications to store their stuff in ~/Library/Application Support Documents is protected on newer macOSes and requires users' explicit permission (and also may be cloud synced), and use of ~/ is fairly uncommon
This commit is contained in:
parent
dabfff8b35
commit
5470f7ff5e
|
@ -152,7 +152,7 @@ namespace PathDefs
|
|||
{
|
||||
switch( mode )
|
||||
{
|
||||
#ifdef XDG_STD
|
||||
#if defined(XDG_STD) || defined(__APPLE__) // Expected location for this kind of stuff on macOS
|
||||
// Move all user data file into central configuration directory (XDG_CONFIG_DIR)
|
||||
case DocsFolder_User: return GetUserLocalDataDir();
|
||||
#else
|
||||
|
|
|
@ -422,6 +422,7 @@ wxMessageOutput* Pcsx2AppTraits::CreateMessageOutput()
|
|||
// Pcsx2StandardPaths
|
||||
// --------------------------------------------------------------------------------------
|
||||
#ifdef wxUSE_STDPATHS
|
||||
#ifndef __APPLE__ // macOS uses wx's defaults
|
||||
class Pcsx2StandardPaths : public wxStandardPaths
|
||||
{
|
||||
public:
|
||||
|
@ -462,11 +463,16 @@ public:
|
|||
#endif
|
||||
|
||||
};
|
||||
#endif // ifdef __APPLE__
|
||||
|
||||
wxStandardPaths& Pcsx2AppTraits::GetStandardPaths()
|
||||
{
|
||||
#ifdef __APPLE__
|
||||
return _parent::GetStandardPaths();
|
||||
#else
|
||||
static Pcsx2StandardPaths stdPaths;
|
||||
return stdPaths;
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue