You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
libcutefish/application/preferences.cpp

19 lines
503 B
C++

#include "preferences.h"
#include <QCoreApplication>
#include <QStandardPaths>
QString Preferences::file(const QString &process)
{
return QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation)
+ QLatin1String("/cutefish/") + process + QLatin1String(".conf");
}
QString Preferences::ownFile()
{
QString process = QCoreApplication::applicationName();
if (process.startsWith(QLatin1String("cutefish-")))
process.remove(0, 9);
return file(process);
}