Validate pieces each time we activate a sheet.

This commit is contained in:
Roman Telezhynskyi 2024-04-08 20:18:33 +03:00
parent c5a3375d78
commit f72d235344

View File

@ -327,6 +327,16 @@ void VPLayout::SetFocusedSheet(const VPSheetPtr &focusedSheet)
m_focusedSheet = focusedSheet.isNull() ? m_sheets.constFirst() : focusedSheet;
}
if (LayoutSettings().GetWarningSuperpositionOfPieces())
{
m_focusedSheet->ValidateSuperpositionOfPieces();
}
if (LayoutSettings().GetWarningPieceGapePosition())
{
m_focusedSheet->ValidatePieceGapePosition();
}
emit ActiveSheetChanged(m_focusedSheet);
}