From fa94de884bf15f47278ccb6e93d31c422aef9c2c Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 6 Jul 2016 13:42:56 -0400 Subject: Enable starting fluxbox within the start-lumina-desktop utility (lumina-session). --- src-qt5/core/lumina-session/session.cpp | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'src-qt5/core') diff --git a/src-qt5/core/lumina-session/session.cpp b/src-qt5/core/lumina-session/session.cpp index 384c75f9..fbe5fa44 100644 --- a/src-qt5/core/lumina-session/session.cpp +++ b/src-qt5/core/lumina-session/session.cpp @@ -67,9 +67,22 @@ void LSession::start(){ } //Window Manager First // FLUXBOX BUG BYPASS: if the ~/.fluxbox dir does not exist, it will ignore the given config file - //if(!QFile::exists(QDir::homePath()+"/.fluxbox")){ QDir dir; dir.mkpath(QDir::homePath()+"/.fluxbox"); } - //startProcess("wm", "fluxbox -rc "+QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/fluxbox-init -no-slit -no-toolbar"); - + if( !LUtils::isValidBinary("fluxbox") ){ + qDebug() << "[INCOMPLETE LUMINA INSTALLATION] fluxbox binary is missing - cannot continue"; + }else{ + QString confDir = QString( getenv("XDG_CONFIG_HOME"))+"/lumina-desktop"; + if(!QFile::exists(confDir)){ QDir dir(confDir); dir.mkpath(confDir); } + if(!QFile::exists(confDir+"/fluxbox-init")){ + QFile::copy(":/fluxboxconf/fluxbox-init-rc",confDir+"/fluxbox-init"); + QFile::setPermissions(confDir+"/fluxbox-init", QFile::ReadOwner | QFile::WriteOwner | QFile::ReadUser | QFile::ReadOther | QFile::ReadGroup); + } + // FLUXBOX BUG BYPASS: if the ~/.fluxbox dir does not exist, it will ignore the given config file + if(!QFile::exists(QDir::homePath()+"/.fluxbox")){ + QDir dir; dir.mkpath(QDir::homePath()+"/.fluxbox"); + } + QString cmd = "fluxbox -rc "+confDir+"/fluxbox-init -no-slit -no-toolbar"; + startProcess("wm", cmd, QStringList() << confDir+"/fluxbox-init" << confDir+"/fluxbox-keys"); + } //Compositing manager if(LUtils::isValidBinary("compton")){ QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; -- cgit