mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fix(macos): Fix macOS autorun not loading at start
macOS system.log was reporting "Unknown key for integer: RunAtLoad" and not loading qTox at start despite ~/Library/LaunchAgents/chat.tox.qtox.autorun.plist being present. Changing the type from an int to a bool causes it to load successfully on boot. Fix #2814
This commit is contained in:
parent
4c969a9277
commit
009369118f
|
@ -25,11 +25,12 @@
|
|||
#include <QStandardPaths>
|
||||
|
||||
namespace {
|
||||
int state;
|
||||
bool state;
|
||||
} // namespace
|
||||
|
||||
bool Platform::setAutorun(const Settings&, bool on)
|
||||
bool Platform::setAutorun(const Settings& settings, bool on)
|
||||
{
|
||||
std::ignore = settings;
|
||||
QString qtoxPlist =
|
||||
QDir::cleanPath(QStandardPaths::writableLocation(QStandardPaths::HomeLocation)
|
||||
+ QDir::separator() + "Library" + QDir::separator() + "LaunchAgents"
|
||||
|
@ -45,7 +46,8 @@ bool Platform::setAutorun(const Settings&, bool on)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool Platform::getAutorun(const Settings&)
|
||||
bool Platform::getAutorun(const Settings& settings)
|
||||
{
|
||||
std::ignore = settings;
|
||||
return state;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user