diff options
Diffstat (limited to 'src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp')
-rw-r--r-- | src-qt5/core/lumina-desktop-unified/src-desktop/src-cpp/RootDesktopObject.cpp | 15 |
1 files changed, 13 insertions, 2 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 9842712e..60cf56c3 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 @@ -32,8 +32,19 @@ RootDesktopObject* RootDesktopObject::instance(){ } //QML Read Functions -QList<ScreenObject*> RootDesktopObject::screens(){ - return s_objects; +QStringList RootDesktopObject::screens(){ + qDebug() << "Request Screens:" << s_objects.length(); + QStringList names; + for(int i=0; i<s_objects.length(); i++){ names << s_objects[i]->name(); } + return names; +} + +ScreenObject* RootDesktopObject::screen(QString id){ + qDebug() << "Got Screen Request:" << id; + for(int i=0; i<s_objects.length(); i++){ + if(s_objects[i]->name()==id){ return s_objects[i]; } + } + return 0; } void RootDesktopObject::logout(){ |