From 2bc4e63431148a53a968fea13dc2819f03679498 Mon Sep 17 00:00:00 2001 From: Michail Vourlakos Date: Thu, 19 Mar 2020 01:44:52 +0200 Subject: [PATCH] fix a case to autoupdate free_activities_id --when free_activities layout becomes shared then another layout should become responsible for FREE_ACTIVITIES --- app/settings/models/layoutsmodel.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/app/settings/models/layoutsmodel.cpp b/app/settings/models/layoutsmodel.cpp index 402e71c86..be51f9c23 100644 --- a/app/settings/models/layoutsmodel.cpp +++ b/app/settings/models/layoutsmodel.cpp @@ -427,7 +427,7 @@ void Layouts::autoAssignFreeActivitiesLayout() QString activeCurrentId = m_layoutsTable.idForOriginalName(m_corona->layoutsManager()->currentLayoutName()); int row = m_layoutsTable.indexOf(activeCurrentId); - if (row>=0 && m_layoutsTable[row].activities.isEmpty()) { + if (row>=0 && !(m_inMultipleMode && m_layoutsTable[row].isShared()) && m_layoutsTable[row].activities.isEmpty()) { m_layoutsTable[row].activities << Data::Layout::FREEACTIVITIESID; emit dataChanged(index(row,BACKGROUNDCOLUMN), index(row,ACTIVITYCOLUMN), roles); return; @@ -435,7 +435,7 @@ void Layouts::autoAssignFreeActivitiesLayout() //! Active layouts with no activities have mid priority for(int i=0; i