diff options
Diffstat (limited to 'lumina-desktop/panel-plugins')
-rw-r--r-- | lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp | 4 | ||||
-rw-r--r-- | lumina-desktop/panel-plugins/systemtray/LSysTray.cpp | 3 | ||||
-rw-r--r-- | lumina-desktop/panel-plugins/userbutton/UserWidget.cpp | 4 |
3 files changed, 6 insertions, 5 deletions
diff --git a/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp b/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp index 163f7c0a..71eaa8c4 100644 --- a/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp +++ b/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp @@ -35,6 +35,7 @@ LDeskBarPlugin::LDeskBarPlugin(QWidget *parent, QString id, bool horizontal) : L connect(watcher, SIGNAL(directoryChanged(QString)), this, SLOT(desktopChanged()) ); QTimer::singleShot(1,this, SLOT(desktopChanged()) ); //make sure to load it the first time QTimer::singleShot(0,this, SLOT(OrientationChange()) ); //adjust sizes/layout + connect(QApplication::instance(), SIGNAL(DesktopFilesChanged()), this, SLOT(desktopChanged()) ); } LDeskBarPlugin::~LDeskBarPlugin(){ @@ -144,8 +145,7 @@ void LDeskBarPlugin::desktopChanged(){ QStringList newfavs = LUtils::listFavorites(); if(lastHomeUpdate.isNull() || (QFileInfo(QDir::homePath()+"/Desktop").lastModified() > lastHomeUpdate) || newfavs!=favs ){ favs = newfavs; - QDir homedir = QDir( QDir::homePath()+"/Desktop"); - homefiles = homedir.entryInfoList(QDir::Files | QDir::Dirs | QDir::NoDotAndDotDot); + homefiles = LSession::handle()->DesktopFiles(); lastHomeUpdate = QDateTime::currentDateTime(); QStringList favitems = favs; //Remember for format for favorites: <name>::::[app/dir/<mimetype>]::::<full path> diff --git a/lumina-desktop/panel-plugins/systemtray/LSysTray.cpp b/lumina-desktop/panel-plugins/systemtray/LSysTray.cpp index 1b458f0c..519a5e23 100644 --- a/lumina-desktop/panel-plugins/systemtray/LSysTray.cpp +++ b/lumina-desktop/panel-plugins/systemtray/LSysTray.cpp @@ -36,7 +36,8 @@ LSysTray::LSysTray(QWidget *parent, QString id, bool horizontal) : LPPlugin(pare connect(upTimer, SIGNAL(timeout()), this, SLOT(checkAll()) ); isRunning = false; stopping = false; checking = false; pending = false; QTimer::singleShot(100, this, SLOT(start()) ); - + //Also do one extra check a minute or so after startup (just in case something got missed in the initial flood of registrations) + QTimer::singleShot(90000,this, SLOT(checkAll()) ); connect(LSession::handle(), SIGNAL(TrayListChanged()), this, SLOT(checkAll()) ); connect(LSession::handle(), SIGNAL(TrayIconChanged(WId)), this, SLOT(UpdateTrayWindow(WId)) ); connect(LSession::handle(), SIGNAL(VisualTrayAvailable()), this, SLOT(start()) ); diff --git a/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp b/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp index d1173ee1..bae14b5a 100644 --- a/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp +++ b/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp @@ -89,6 +89,7 @@ UserWidget::UserWidget(QWidget* parent) : QTabWidget(parent), ui(new Ui::UserWid lastUpdate = QDateTime(); //make sure it refreshes connect(LSession::handle()->applicationMenu(), SIGNAL(AppMenuUpdated()), this, SLOT(UpdateMenu()) ); + connect(QApplication::instance(), SIGNAL(DesktopFilesChanged()), this, SLOT(updateFavItems()) ); QTimer::singleShot(10,this, SLOT(UpdateMenu())); //make sure to load this once after initialization } @@ -176,8 +177,7 @@ void UserWidget::updateFavItems(bool newfilter){ if(lastHomeUpdate.isNull() || (QFileInfo(QDir::homePath()+"/Desktop").lastModified() > lastHomeUpdate) || newfavs!=favs ){ favs = newfavs; - QDir homedir = QDir( QDir::homePath()+"/Desktop"); - homefiles = homedir.entryInfoList(QDir::Files | QDir::Dirs | QDir::NoDotAndDotDot); + homefiles = LSession::handle()->DesktopFiles(); lastHomeUpdate = QDateTime::currentDateTime(); }else if(!newfilter){ return; } //nothing new to change - stop now QStringList favitems; |