From ac91cd2195ab9a4d2bc1547594574c2a39352525 Mon Sep 17 00:00:00 2001 From: Chani Armitage Date: Sat, 2 Oct 2010 17:04:24 +0000 Subject: [PATCH] activity associations are saved with kwin's session svn path=/trunk/KDE/kdebase/workspace/; revision=1181900 --- manage.cpp | 1 + sm.cpp | 2 ++ sm.h | 1 + 3 files changed, 4 insertions(+) diff --git a/manage.cpp b/manage.cpp index 1149e6c0f7..20358add2c 100644 --- a/manage.cpp +++ b/manage.cpp @@ -167,6 +167,7 @@ bool Client::manage( Window w, bool isMapped ) desk = session->desktop; if( session->onAllDesktops ) desk = NET::OnAllDesktops; + setOnActivities(session->activities); } else { diff --git a/sm.cpp b/sm.cpp index 9b7fbd54f2..944ac4b0cb 100644 --- a/sm.cpp +++ b/sm.cpp @@ -145,6 +145,7 @@ void Workspace::storeSession( KConfig* config, SMSavePhase phase ) // KConfig doesn't support long so we need to live with less precision on 64-bit systems static_cast( reinterpret_cast( c->clientGroup() )) : 0; cg.writeEntry( QString("clientGroup")+n, group ); + cg.writeEntry( QString("activities")+n, c->activities() ); } } if( phase == SMSavePhase0 ) @@ -217,6 +218,7 @@ void Workspace::loadSessionInfo() info->stackingOrder = cg.readEntry( QString("stackingOrder")+n, -1 ); info->clientGroup = cg.readEntry( QString("clientGroup")+n, 0 ); info->clientGroupClient = NULL; + info->activities = cg.readEntry( QString("activities")+n, QStringList() ); } } diff --git a/sm.h b/sm.h index cbae725001..b619507379 100644 --- a/sm.h +++ b/sm.h @@ -68,6 +68,7 @@ struct SessionInfo int clientGroup; // Unique identifier for the client group that this window is in Client* clientGroupClient; // The first client created that has an identical identifier + QStringList activities; };