Commit 0dbb399d authored by Robert Lancaster's avatar Robert Lancaster Committed by Jasem Mutlaq

KLauncher handling on OSX

parent f27f7b4b
......@@ -71,6 +71,13 @@ KStars::KStars( bool doSplash, bool clockrun, const QString &startdate )
setWindowTitle(i18n("KStars"));
//On OS X, need to launch kdeinit5 so you can get KLauncher and KIOSlave so you can download new data.
//Note: You need to make sure the environment variables for KStars are set correctly to get this running properly.
#ifdef Q_OS_OSX
QProcess* klauncher = new QProcess(this);
klauncher->start("kdeinit5");
#endif
// Initialize logging settings
if (Options::disableLogging())
KSUtils::Logging::Disable();
......
......@@ -1456,6 +1456,18 @@ void KStars::slotAboutToQuit()
//synch the config file with the Config object
writeConfig();
//Terminate Child Processes if on OS X
#ifdef Q_OS_OSX
QProcess* quit = new QProcess(this);
quit->start("killall kdeinit5");
quit->waitForFinished(1000);
quit->start("killall klauncher");
quit->waitForFinished(1000);
quit->start("killall kioslave");
quit->waitForFinished(1000);
delete quit;
#endif
}
void KStars::slotShowPositionBar(SkyPoint* p )
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment