aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp
diff options
context:
space:
mode:
authorKen Moore <ken@ixsystems.com>2018-01-02 15:57:56 -0500
committerKen Moore <ken@ixsystems.com>2018-01-02 15:57:56 -0500
commit6cbd6541d5536f59973ba625b267eb8ad64d747b (patch)
tree029c4758155d1b19cd3afd9fe659c35d0009d94e /src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp
parentFinished transitioning from QPrintPreviewWidget to QGraphicsView (diff)
downloadlumina-6cbd6541d5536f59973ba625b267eb8ad64d747b.tar.gz
lumina-6cbd6541d5536f59973ba625b267eb8ad64d747b.tar.bz2
lumina-6cbd6541d5536f59973ba625b267eb8ad64d747b.zip
Add the new "DesktopManager" class into lumina2 sources.
This is the class that watches for settings file changes and/or converts settings into interface object values.
Diffstat (limited to 'src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp')
-rw-r--r--src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp8
-rw-r--r--src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp b/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp
index 5750ac2d..4b01fa0d 100644
--- a/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp
+++ b/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp
@@ -129,5 +129,13 @@ void RootDesktopObject::ChangeWallpaper(QString screen, QString value){
}
}
+QString RootDesktopObject::CurrentWallpaper(QString screen){
+ for(int i=0; i<s_objects.length(); i++){
+ if(s_objects[i]->name()==screen){ return s_objects[i]->background();}
+ }
+ return ""; //unknown
+}
+
+
// === PRIVATE ===
diff --git a/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.h b/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.h
index 838b5f7d..7d5182c4 100644
--- a/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.h
+++ b/src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.h
@@ -55,6 +55,7 @@ private:
public slots:
void updateScreens(); //rescan/update screen objects
void ChangeWallpaper(QString screen, QString);
+ QString CurrentWallpaper(QString screen);
private slots:
bgstack15