From 5461b27f0ed308754f34ea37b30d9eaa18c85994 Mon Sep 17 00:00:00 2001 From: lupoDharkael Date: Thu, 22 Feb 2018 16:39:46 +0100 Subject: [PATCH] Improve content of autostart file --- src/utils/confighandler.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/utils/confighandler.cpp b/src/utils/confighandler.cpp index 52a9d966..bf6b658a 100644 --- a/src/utils/confighandler.cpp +++ b/src/utils/confighandler.cpp @@ -202,7 +202,10 @@ void ConfigHandler::setStartupLaunch(const bool start) { QFile file(path); if (start) { if (file.open(QIODevice::WriteOnly)) { - file.write("[Desktop Entry]\nIcon=system-run\nExec=flameshot\nTerminal=false"); + QByteArray data("[Desktop Entry]\nEncoding=UTF-8\nName=flameshot" + "\nIcon=flameshot\nExec=flameshot\nTerminal=false" + "\nType=Application\nX-GNOME-Autostart-enabled=true\n"); + file.write(data); } } else { file.remove();