From 6359a983970e4fe6623bcb7f63ee9248f06cebf2 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sat, 13 Jun 2015 21:12:54 -0700 Subject: system_default_directory() is broken with Qt 5.4 So for now just keep using the same function as we use with earlier versions of Qt5 as that seems to work. Signed-off-by: Dirk Hohndel --- qthelper.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/qthelper.cpp b/qthelper.cpp index e25be9c26..39c259992 100644 --- a/qthelper.cpp +++ b/qthelper.cpp @@ -355,11 +355,15 @@ extern "C" const char *system_default_directory(void) if (!*filename) { enum QStandardPaths::StandardLocation location; -#if QT_VERSION >= 0x050400 - location = QStandardPaths::AppDataLocation; -#else + + // allegedly once you're on Qt5.4 or later you should use + // QStandardPaths::AppDataLocation but on Mac that gives us + // paths starting with /Library/... + // #if QT_VERSION >= 0x050400 + // location = QStandardPaths::AppDataLocation; + // #else location = QStandardPaths::DataLocation; -#endif + // #endif QString name = QStandardPaths::standardLocations(location).first(); QDir dir(name); dir.mkpath(name); -- cgit v1.2.3-70-g09d2