aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/core/lumina-desktop/LSession.cpp
diff options
context:
space:
mode:
authorKen Moore <moorekou@gmail.com>2016-06-14 13:21:29 -0400
committerKen Moore <moorekou@gmail.com>2016-06-14 13:21:29 -0400
commitf6bb0b0e52214a7235cc64dc7a52fb4fbaa61a3c (patch)
tree1a045f6368ad50ecb5118f95f3e377ec3226ff75 /src-qt5/core/lumina-desktop/LSession.cpp
parentLarge update to the project files: (diff)
downloadlumina-f6bb0b0e52214a7235cc64dc7a52fb4fbaa61a3c.tar.gz
lumina-f6bb0b0e52214a7235cc64dc7a52fb4fbaa61a3c.tar.bz2
lumina-f6bb0b0e52214a7235cc64dc7a52fb4fbaa61a3c.zip
Another large batch of updates:
1) Move the "runtime" directory in the users home to the XDG_CONFIG_HOME/lumina-desktop rather than ~/.lumina 2) Update the Glass theme a bit more.
Diffstat (limited to 'src-qt5/core/lumina-desktop/LSession.cpp')
-rw-r--r--src-qt5/core/lumina-desktop/LSession.cpp21
1 files changed, 11 insertions, 10 deletions
diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp
index 9444edd6..5de9920d 100644
--- a/src-qt5/core/lumina-desktop/LSession.cpp
+++ b/src-qt5/core/lumina-desktop/LSession.cpp
@@ -92,9 +92,8 @@ void LSession::setupSession(){
//Setup the QSettings default paths
splash.showScreen("settings");
if(DEBUG){ qDebug() << " - Init QSettings:" << timer->elapsed();}
- QSettings::setPath(QSettings::NativeFormat, QSettings::UserScope, QDir::homePath()+"/.lumina");
- sessionsettings = new QSettings("LuminaDE", "sessionsettings");
- DPlugSettings = new QSettings("pluginsettings","desktopsettings");
+ sessionsettings = new QSettings("lumina-desktop", "sessionsettings");
+ DPlugSettings = new QSettings("lumina-desktop","pluginsettings/desktopsettings");
//Load the proper translation files
if(sessionsettings->value("ForceInitialLocale",false).toBool()){
//Some system locale override it in place - change the env first
@@ -150,11 +149,13 @@ void LSession::setupSession(){
qDebug() << " - Initialize file system watcher";
if(DEBUG){ qDebug() << " - Init QFileSystemWatcher:" << timer->elapsed();}
watcher = new QFileSystemWatcher(this);
- //watcher->addPath( QDir::homePath()+"/.lumina/stylesheet.qss" );
- watcher->addPath( QDir::homePath()+"/.lumina/LuminaDE/sessionsettings.conf" );
- watcher->addPath( QDir::homePath()+"/.lumina/LuminaDE/desktopsettings.conf" );
- watcher->addPath( QDir::homePath()+"/.lumina/fluxbox-init" );
- watcher->addPath( QDir::homePath()+"/.lumina/fluxbox-keys" );
+ QString confdir = sessionsettings->fileName().section("/",0,-2);
+ watcher->addPath( sessionsettings->fileName() );
+ watcher->addPath( confdir+"/desktopsettings.conf" );
+ watcher->addPath( confdir+"/fluxbox-init" );
+ watcher->addPath( confdir+"/fluxbox-keys" );
+ //Try to watch the localized desktop folder too
+ if(QFile::exists(QDir::homePath()+"/"+tr("Desktop"))){ watcher->addPath( QDir::homePath()+"/"+tr("Desktop") ); }
watcher->addPath( QDir::homePath()+"/Desktop" );
//connect internal signals/slots
@@ -322,8 +323,8 @@ void LSession::watcherChange(QString changed){
if(changed.endsWith("fluxbox-init") || changed.endsWith("fluxbox-keys")){ refreshWindowManager(); }
else if(changed.endsWith("sessionsettings.conf") ){ sessionsettings->sync(); emit SessionConfigChanged(); }
else if(changed.endsWith("desktopsettings.conf") ){ emit DesktopConfigChanged(); }
- else if(changed == QDir::homePath()+"/Desktop"){
- desktopFiles = QDir(QDir::homePath()+"/Desktop").entryInfoList(QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs ,QDir::Name | QDir::IgnoreCase | QDir::DirsFirst);
+ else if(changed == QDir::homePath()+"/Desktop" || changed == QDir::homePath()+"/"+tr("Desktop") ){
+ desktopFiles = QDir(changed).entryInfoList(QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs ,QDir::Name | QDir::IgnoreCase | QDir::DirsFirst);
if(DEBUG){ qDebug() << "New Desktop Files:" << desktopFiles.length(); }
emit DesktopFilesChanged();
}
bgstack15