create local autostart folder if is missing

BUG: 402934
pull/4/head
Michail Vourlakos 6 years ago
parent 80ef0d58dd
commit 8c21ca9072

@ -330,6 +330,13 @@ void UniversalSettings::setAutostart(bool state)
autostartFile.remove();
emit autostartChanged();
} else if (state && metaFile.exists()) {
//! check if autostart folder exists and create otherwise
QDir autostartDir(QDir::homePath() + "/.config/autostart");
if (!autostartDir.exists()) {
QDir configDir(QDir::homePath() + "/.config");
configDir.mkdir("autostart");
}
metaFile.copy(autostartFile.fileName());
//! I haven't added the flag "OnlyShowIn=KDE;" into the autostart file
//! because I fall onto a Plasma 5.8 case that this flag

Loading…
Cancel
Save